Intel HAXM on macOS high sierra (10.13)

45,019

Solution 1

The command line installation doesn't work and gives unsupported mac os version error, while the installation through IntelHAXM_6.2.1.mpkg works but kext is not loaded due to "Approved Kernel Extension Loading" changes,

So you will need to allow the extensions from Intel and restart your mac, then launch the emulator like from inside Android Studio,

To enable go to System Preferences > Security & Privacy as shown in the screenshot:

enter image description here

Solution 2

I was able to install Intel HAXM drivers on my Mac using the instructions provided in this post. There might be other (better) solutions to this, but I have successfully managed to start the emulator this way. Essentially you need to disable the security protection on kext before trying to install the HAXM drivers.

This command will only work on Recovery OS, which means that you need to restart your Mac and hold command + R until the Apple logo is displayed. Next, you need to go to Utilities > Terminal and run:

csrutil enable --without kext

Then restart your Mac and log in, go here to download the latest Intel HAXM driver. Unzip if needed, edit the silent_install.sh file and search for the 10.12 OS version. You will find it on the line which should look like this

for v in 10.8 10.9 10.10 10.11 10.12

You need to add the 10.13 version after 10.12 (separated by space, just like the rest). Save the file and open a Terminal at this location. Run ./silent_install.sh and that should be it. To be sure it works, you can also run sudo kextload -bundle-id com.intel.kext.intelhaxm.

Now your emulator should work.

In order to re-enable the kext security protection, you need to restart your Mac in Recovery OS, open a Terminal window and run csrutil enable.

Solution 3

Use the new Hypervisor.Framework support on macOS.

Add this line in ~/.android/advancedFeatures.ini (create this file if it doesn't exist already).

HVF = on

Issue answered here: https://issuetracker.google.com/issues/62395878#comment7

That's worked for me.

Also you can be updated with Intel HAXM as they fixed this error.

Download HAXM latest version here (Restart macOS Required):

https://software.intel.com/en-us/android/articles/intel-hardware-accelerated-execution-manager-end-user-license-agreement-macosx

Hope it help.

Solution 4

To verify that Intel HAXM is running, open a terminal window and execute the following command:

kextstat | grep intel

If Intel HAXM is operating correctly, the command will show a status message indicating that the kernel extension named com.intel.kext.intelhaxm is loaded.

Try to stop and stat again HAXM., than verify it works correctly.

To stop Intel HAXM, use the following commands:

sudo kextunload -b com.intel.kext.intelhaxm

To start Intel HAXM, use the following commands:

sudo kextload -b com.intel.kext.intelhaxm

Solution 5

You can use Google's 6.2.1's silent_installer.sh to properly install HAXM on High Sierra:

https://dl.google.com/android/repository/extras/intel/haxm-macosx_r6_2_1.zip

Otherwise use Android Studio's SDK Manager to download and install it for you:

This was not introduced until 6.2.1(Google Distribution only) which looks like a hotfix from the 6.2.0 version which would throw the following message:

HAXM silent installation only supports macOS from 10.8 to 10.12!

If you don't want to use HAXM, you can use the Hypervisor.Framework by ensuring you have installed Android Emulator 26.1.3

Documentation

The emulator is now fully compatible with macOS 10.13 High Sierra through either Hypervisor.Framework or HAXM 6.2.0.

https://developer.android.com/studio/releases/emulator.html#26-1-3

Share:
45,019
Andrii Kovalchuk
Author by

Andrii Kovalchuk

Android/Flutter developer

Updated on December 11, 2020

Comments

  • Andrii Kovalchuk
    Andrii Kovalchuk over 3 years

    Is there any way of using Android emulator on High Sierra (10.13)?

    When I run

    ./HAXM\ installation -u
    

    It says:

    HAXM silent installation only supports macOS from 10.8 to 10.12 !
    
  • nikoss
    nikoss over 6 years
    have you read the question? because the question is about how to install haxm on high sierra which doesn't satisfy haxm max installable os which is Sierra. ![](i.imgur.com/aM7GlWe.png)
  • Can Uludağ
    Can Uludağ over 6 years
    Yeap. It says it's not supported but re-install solved my issue. After updating to High Sierra, Android emulators stopped working. Then I re-installed the HAXM with the link above. Emulators started to work again.
  • nikoss
    nikoss over 6 years
    I don't know how you did it but for me its just impossible to install and so for the author of this post as I understand. So we can't install it not that it fails working.
  • Jalal El-Shaer
    Jalal El-Shaer over 6 years
    Great work around. Any thoughts about the implications of such change ? Why would Intel support "officially" up to 10.12 ?
  • Octavian Mărculescu
    Octavian Mărculescu over 6 years
    @JalalEl-Shaer I don't think there are any side effects of installing the HAXM drivers this way. It seems that the Intel guys need to remove a workaround for an old bug in the XNU kernel which was fixed in 10.13.
  • Zayin Krige
    Zayin Krige over 6 years
    csrutil enable --with kext didnt work for me on 10.13. I had to run csrutil clear to reset SIP
  • huey77
    huey77 over 6 years
    What is that and how do you use it? I looked at that post and didn't get much from it, other then what you just stated.
  • Jagjot
    Jagjot over 6 years
    For some users the location for advancedFeatures.ini would be this /Users/<username>/Library/Android/sdk/emulator/lib
  • Felix
    Felix over 6 years
    When I click on allow nothing happens. Even after a restart. What can I do?
  • Felix
    Felix over 6 years
    I selected the allow button by pressing tab multiple times and then "clicked" the button with space. It works now, lol.
  • Cosmin
    Cosmin over 6 years
    @Felix - Same for me. Nothing happens. Were you able to fix the issue?
  • Cosmin
    Cosmin over 6 years
    @Felix - It turns out that it doesn't work via ScreenShare or SSH, so you need to be physically at the machine and use a Keyboard and Mouse - github.com/tekezo/Karabiner-Elements/issues/1017
  • Shaz
    Shaz over 6 years
    @aeid, make sure that you installed HAXM through .mpkg file without issues
  • ToolmakerSteve
    ToolmakerSteve about 6 years
    FWIW, double-click on .dmg to see the .mpkg
  • shoke
    shoke over 5 years
    So when I clicked allow nothing happens, but the installation eventually succeeds. So yeah, just gotta wait a bit.
  • Lukas
    Lukas over 5 years
    Incomplete check answer from @Shaz
  • Brent
    Brent over 5 years
    It's not incomplete, as this is exactly how I fixed my issue. You might not like my answer, but it fixed my problem.
  • Lukas
    Lukas over 5 years
    What I meant to say is you left out the part where in addition to the Unlock button you need to click the Allow button as well.
  • Skoempie
    Skoempie over 5 years
    Thank you very much, after searching for hours this was my solution! I've installed HAXM on Mac but it didn't work, AVD still said that HAXM was missing. After installation you can validate with kextstat | grep intel. If it returns nothing then something is wrong you need to allow Intel in Security and Privacy.
  • Fran Marzoa
    Fran Marzoa almost 5 years
    I don't even have that warning with the "Allow" button there... :(
  • Fran Marzoa
    Fran Marzoa almost 5 years
    This is about Mac, not a PC.
  • Daniel Gomez Rico
    Daniel Gomez Rico over 4 years
    I just installed in Mojave and it appeared there, THANKS!