31

Windows phone emulator requires Hyper-V to run, but Android emulator in turn requires Intel Hardware Acceleration Manager (HAXM), which is intolerant to Hyper-V.

Is there a way to keep Hyper-V and disable it temporarily to have Intel HAXM operational, without rebooting?

  1. I run Windows Hyper-V manager and stopped the server (this involves stopping all services), but that didn't help: Android emulator still refused to start.

  2. I called services.msc to see if some Hyper-V services were still running. Indeed, all services starting with Hyper-V were NOT running. I also stopped HV Host service (Microsoft Hypervisor Host service), but it still didn't help!

Any ideas?

cyanide
  • 3,885
  • 3
  • 25
  • 33
  • 4
    There is no way to co-exist Hyper-V and HAXM. But now, Hyper-V can replace HXML as Android Emulator accelerator. See this: https://blogs.msdn.microsoft.com/visualstudio/2018/05/08/hyper-v-android-emulator-support/ – Junle Li Jul 10 '18 at 14:09

3 Answers3

21

Update to Windows 10 v1801 and April 2018 update and it will work. Windows now supports Android emulation using Hyper-V. Thanks to @JunleLi for the tip.

https://blogs.msdn.microsoft.com/visualstudio/2018/05/08/hyper-v-android-emulator-support/

TetraDev
  • 16,074
  • 6
  • 60
  • 61
  • Does the Android emulator works good with Hyper-V? Have you a comparison to HAXM (don't work in my case)? I think about to install VS 2017 15.8 (installed 15.7) and change to Hyper-V and want to know, if Hyper-V works without issues before. Thanks. – FredyWenger Aug 23 '18 at 11:40
  • 2
    It does work as expected using the new windows update with Hyper-V and Windows HyperVisor Platform featuers enabled. I could not notice any difference over using HAXM - other than being able to use Android Emulator and Docker at the same time ;0) – TetraDev Aug 30 '18 at 21:28
  • Thanks @TetraDev. I was able to bring HAXM to work in the meantime (I had to update the Android Emulator in the Android APK to the newest version and before had to deactivate "suggested from Microsoft" to see the update). Now it seems to work as it should principally... – FredyWenger Aug 31 '18 at 12:54
  • 3
    What about Android Studio though? That's for Visual Studio only. – kb1000 Jun 24 '20 at 10:00
14

This is probably the best work around:

http://blogs.msdn.com/b/virtual_pc_guy/archive/2008/04/14/creating-a-no-hypervisor-boot-entry.aspx

You keep two BCD entries referring to same Windows 10 partition, but one with Hyper-V activated (hypervisorlaunchtype Auto), and another one with Hyper-V suppressed (hypervisorlaunchtype Off). Still you have to reboot the system, but no need to install/uninstall Hyper-V, which is a significant relief.

A proposito, this article uses bcdedit which is a standard Windows command line utility. As an alternative, you can use a GUI application Visual BCD editor

cyanide
  • 3,885
  • 3
  • 25
  • 33
  • Excuse me, any progress on this? Found some way to start and stop Hyper-V without reboot, without install and reinstall, and via command line? Sorry to take your time. Many thanks, best of all. – statosdotcom Mar 07 '17 at 16:52
  • There's also an Android emulator by Microsoft that can co-exist with Hyper-V: https://www.visualstudio.com/en-us/features/msft-android-emulator-vs.aspx. Instructions on how to install and configure can be found in http://www.itwriting.com/blog/9371-how-to-run-android-studio-on-windows-without-disabling-hyper-v.html. However, it seems it doesn't yet support Nougat; it only goes as high as Marshmallow. Oh, well. – YSK Mar 13 '17 at 14:45
  • 1
    I also use Microsoft Emulator. You just take IP address form Network tab, say "adb connect ip-address" and can use it everywhere. Unfortunately it doesn't support Android 7. – cyanide Mar 14 '17 at 21:18
10

You cannot disable Hyper-V without booting.

  • Hyper-V is a type 1 hypervisor. It runs on the bare metal.
  • When you run Windows 10 with the Hyper-V enabled, the Windows root OS runs on the Hyper-V.
  • When you run Windows 10 with the Hyper-V disabled, the Windows runs on the bare metal without the Hyper-V in the middle.

The only way to "remove" the Hyper-V below the Windows is restarting the machine.

Jaime
  • 5,435
  • 2
  • 18
  • 21