Can't using Docker for Mac with Android Emulator (HAXM)

Expected behavior

I hope using Docker and Android Emulator same time.

Actual behavior

I can’t using both same time.
but I can using Parallels Desktop and Android Emulator

Information

I did run Android Emulator in Android Studio
and I got error messages…

emulator: WARNING: VM heap size set below hardware specified minimum of 256MB
emulator: WARNING: Setting VM heap size to 384MB
Hax is enabled
Hax ram_size 0x60000000
HAX is working and emulator runs in fast virt mode.
console on port 5554, ADB on port 5555
Failed to sync vcpu reg
emulator: ERROR: Unfortunately, there’s an incompatibility between HAXM hypervisor and VirtualBox 4.3.30+ which doesn’t allow multiple hypervisors to co-exist. It is being actively worked on; you can find out more about the issue at Report and track bugs  |  Android Open Source Project (Android) and #14294 (Cannot launch both VirtualBox virtual machine and HAXM at the same time -> fixed in HAXM, see last comments) – Oracle VirtualBox (VirtualBox)
Failed to sync vcpu reg
Failed to sync vcpu reg
Internal error: initial hax sync failed

Steps to reproduce the behavior

  1. start docker for mac
  2. start android emulator
5 Likes

I’m having the same issue.
Quite mind-blowing, to be honest! :slight_smile:

1 Like

Thanks for the report! This one appears tricky to fix with the current Hypervisor.framework, but we’re investigating further…

4 Likes

Any news for this?

Is this viable once Docker left VirtualBox behind and adopted xhyve? Can Apple’s Hypervisor.framework be tamed to behave properly (I don’t know enough to say if this is feasible)?

I’d love to see this issue, if possible, solved, as this is a great opportunity to enable android development alongside a full-stack solution using Docker, and I hate to install tons of services on my machine or have tons of servers to debug every single bug! Docker is so much better to have at hand!

From here https://code.google.com/p/android/issues/detail?id=197915 I see a candidate culprit (if the code in the github is actual and true to the Apple implementation).

2 Likes

We are waiting for fix this issue too.

Super bummed by this issue… it makes react native development very difficult. Any news on this would be helpful.

2 Likes

any news :frowning: I moved recently to Docker for developement

Same as above. Is there any progress on this issue?

1 Like

Any workaround for this issue?

According to this, the problem is solved!

Considering the bug fixed: HAXM 6.1.1 (available as a part of Android Studio or on Intel website at GitHub - intel/haxm: Intel® Hardware Accelerated Execution Manager (Intel® HAXM) ) is designed to coexist with Docker/VirtualBox/HVF hypervisors on Mac OS

Important note, taken on Intel’s website:

The SDK Manager will download the installer to the “extras” directory, under the main SDK directory. Even though the SDK manager says “Installed” it actually means that the Intel HAXM executable was downloaded. You will still need to run the installer from the “extras” directory to finish installation.

1 Like

:+1: Sounds great!!
Thank you!