保留Hyper-V时解决Visual Studio 2022中qemu-system无响应问题
保留Hyper-V时解决Android模拟器qemu-system无响应问题
环境信息
- 使用Visual Studio 2022
- 已通过PowerShell安装Android SDK,执行命令:
cd "C:\Program Files (x86)\Android\android-sdk\cmdline-tools\7.0\bin" .\sdkmanager.bat --list_installed
已安装的SDK包列表:
Installed packages:=====================] 100% Fetch remote repository... Path | Version | Description | Location ------- | ------- | ------- | ------- build-tools;32.0.0 | 32.0.0 | Android SDK Build-Tools 32 | build-tools\32.0.0 build-tools;33.0.0 | 33.0.0 | Android SDK Build-Tools 33 | build-tools\33.0.0 emulator | 31.3.14 | Android Emulator | emulator extras;android;m2repository | 47.0.0 | Android Support Repository | extras\android\m2repository extras;intel;Hardware_Accelerated_Execution_Manager | 7.6.5 | Intel x86 Emulator Accelerator (HAXM installer) | extras\intel\Hardware_Accelerated_Execution_Manager ndk-bundle | 20.1.5948944 | NDK | ndk-bundle patcher;v4 | 1 | SDK Patch Applier v4 | patcher\v4 platform-tools | 33.0.2 | Android SDK Platform-Tools 33.0.2 | platform-tools platforms;android-28 | 6 | Android SDK Platform 28, rev 6 | platforms\android-28 platforms;android-29 | 5 | Android SDK Platform 29, rev 5 | platforms\android-29 platforms;android-31 | 1 | Android SDK Platform 31 | platforms\android-31 platforms;android-33 | 1 | Android SDK Platform 33 | platforms\android-33 system-images;android-28;default;x86_64 | 4 | Intel x86 Atom_64 System Image | system-images\android-28\default\x86_64 system-images;android-29;default;x86_64 | 8 | Intel x86 Atom_64 System Image | system-images\android-29\default\x86_64 system-images;android-31;default;arm64-v8a | 3 | ARM 64 v8a System Image | system-images\android-31\default\arm64-v8a system-images;android-31;default;x86_64 | 3 | Intel x86 Atom_64 System Image | system-images\android-31\default\x86_64 system-images;android-31;google_apis_playstore;x86_64 | 9 | Google Play Intel x86 Atom_64 System Image | system-images\android-31\google_apis_playstore\x86_64 system-images;android-33;google_apis;x86_64 | 5 | Google APIs Intel x86 Atom_64 System Image | system-images\android-33\google_apis\x86_64
- Android设备管理器界面截图:

问题现象
启动Android模拟器时,qemu-system无响应。偶尔使用设备管理器会出现以下错误日志:
Device error: WARNING | unexpected system image feature string, emulator might not function correctly, please try updating the emulator. WARNING | unexpected '-prop' value ('monodroid.avdname=pixel_5_-_api_31'), only 'qemu.' properties are supported WARNING | unexpected '-prop' value ('emu.uuid=5cd6ab71-b279-40b1-b2d0-f506a0f87649'), only 'qemu.' properties are supported dsound: Could not initialize DirectSoundCapture dsound: Reason: No sound driver is available for use, or the given GUID is not a valid DirectSound device ID WARNING | ** No gRPC protection active, consider launching with the -grpc-use-jwt flag.**
检测结果
执行加速检测命令:
"C:\Program Files (x86)\Android\android-sdk\emulator\emulator-check.exe" accel
输出:
accel: 0 Please disable Hyper-V before using the Android Emulator. Start a command prompt as Administrator, run 'bcdedit /set hypervisorlaunchtype off', reboot.WHPX (10.0.22621) is installed and usable. accel
执行systeminfo获取的系统信息:
Host Name: SSOROOSH-PC OS Name: Microsoft Windows 11 Pro OS Version: 10.0.22621 N/A Build 22621 OS Manufacturer: Microsoft Corporation OS Configuration: Standalone Workstation OS Build Type: Multiprocessor Free Registered Organization: Product ID: 00331-10000-00001-AA598 Original Install Date: 11/10/2022, 12:10:44 AM System Boot Time: 12/22/2022, 11:01:09 AM System Manufacturer: ASUS System Model: System Product Name System Type: x64-based PC Processor(s): 1 Processor(s) Installed. [01]: Intel64 Family 6 Model 151 Stepping 2 GenuineIntel ~3400 Mhz BIOS Version: American Megatrends Inc. 1720, 8/12/2022 Windows Directory: C:\WINDOWS System Directory: C:\WINDOWS\system32 Boot Device: \Device\HarddiskVolume13 System Locale: en-us;English (United States) Input Locale: en-us;English (United States)
核心诉求
必须保留Hyper-V,无法通过禁用Hyper-V解决问题,求兼容Hyper-V的解决方案。
内容的提问来源于stack exchange,提问作者sorosh_sabz
相关产品推荐
相关产品推荐

