308

Lately Google and Intel have published a new way to run the emulator, which should work much better than the previous version (which has emulated ARM CPU). Here are some links about it: this and this.

However, after installing the new components and creating a new emulator configuration as instructed, I get an error and I also can't see any improvements. I've tried both API 10 and API 15, and with GPU enabled and disabled. None of those configurations helped. I've also tried it on two different computers and didn't get any boost (and got the same errors).

It seems that on the posts I've read about it, nobody had any problems with it and all report a much faster emulator.

The error it shows is:

emulator: Failed to open the HAX device!
HAX is not working and emulator runs in emulation mode
emulator: Open HAX device failed

Why is it happening, and is there a way to fix it? Is there anyone else who gets those errors or vice versa?

By the way, I have an Intel CPU, if that could be a problem.


EDIT:

here's what I see in the BIOS, so it should be available... :

enter image description here

android developer
  • 106,412
  • 122
  • 641
  • 1,128
  • 68
    Note - the Android SDK Manager does not actually do the installation - you must run the installation yourself after using the manager for the download: /extras/intel/Hardware_Accelerated_Execution_Manager/IntelHAXM.exe – Richard Le Mesurier Sep 12 '12 at 09:47
  • 1
    Richard is correct. I had the same problem, until I followed his comment. Go to http://developer.android.com/tools/devices/emulator.html#accel-vm, and scroll down to the section "Configuring VM Acceleration on Windows". Worked for me, no need to reinstall, or reinstall outside of the ADK, or anything. – Adrian Romanelli Oct 06 '13 at 03:17
  • 7
    On Mac OSX 10,9 nedd also to install manualy hotfix from intel site http://software.intel.com/en-us/android/articles/intel-hardware-accelerated-execution-manager – Zorb Feb 12 '14 at 16:47
  • Thank you! I was having the same issues on my Mac. – bran.io Jul 19 '14 at 05:33
  • Is isochronous support part of VT-x? –  Apr 05 '18 at 17:52

16 Answers16

414

I had the same issue, solved it by Installing the Intel Hardware Accelerated Execution Manager. Download it with the SDK Manager, it's in Extras. After this, go to the folder

[Android SDK Root]\extras\intel\Hardware_Accelerated_Execution_Manager

then run IntelHaxm.exe and install.

Here the link of the Intel Hardware Accelerated IntelHaxm.exe for Microsoft Windows,Mac OS* X, and Linux Ubuntu

enter image description here

You'll get the following message if you don't have virtualization enabled in your BIOS:

enter image description here

hram908
  • 359
  • 5
  • 15
rallrall
  • 4,740
  • 1
  • 13
  • 14
  • 1
    still got some errors when trying to execute the emulator , and the emulation either shows black (when using gpu) or is just slow as before , especially compared to a real device. is this a good configuration: http://tinypic.com/view.php?pic=efgv83&s=6 ? – android developer May 27 '12 at 07:51
  • 1
    I just tested running this with the default hardware setup, was working fine then. This x86 emulator is still pretty new, so there's bound to be a bug or two. Try creating a new AVD and run it with the default HW setup. – rallrall May 27 '12 at 08:44
  • can you please show me how to do this ? maybe i did something wrong . i tried many possible configurations... – android developer May 27 '12 at 08:59
  • Avd Manager -> New -> Target: Android 4.0.3 - API Level 15 -> Intel Atom x86), done. This will give you the basic configuration. If you get errors with this as well, paste some log messages – rallrall May 27 '12 at 09:59
  • still very slow and buggy. this is the configuration: http://tinypic.com/view.php?pic=2db5747&s=6 and this is the messages i get: http://tinypic.com/view.php?pic=r0yqlv&s=6 . i can see that it's slow by running the surfaceView examples on the API-demos app – android developer May 27 '12 at 15:03
  • @android developer Even on my high-end system, the performance difference between the ARM and x86 emulators is barely noticeable. Boot up is faster, and there's slightly less scroll lag, but otherwise it's no better than a low-end real phone. – Ken Y-N May 31 '12 at 01:06
  • so what gives? google has shown a demo about a year ago promising much faster emulation (and it was much faster) , and there are already alternatives that do it much faster (yet they don't have a lot of features and integration to eclipse&adt as the official emulator has) . – android developer May 31 '12 at 07:16
  • Installing the HAXM causes my pc to bluescreen. The emulator works for me without it, even though I get the error message mentioned above. – Liron Oct 19 '12 at 07:05
  • You might have to run as admin if you get error downloading from SDK manager. (by right clicking the C:\Program Files\Android\android-sdk\SDK Manager and selecting run as Administrator). – NoBugs Nov 08 '12 at 02:45
  • Is there a similar installer for Linux? – NoBugs Nov 08 '12 at 02:46
  • Thanks! It runs very fast on HP ProBook 6550b (cpu i5 520m), it looks to me it's almost fast as on a real high end device. Emulator starts in 5-10s. Even no-gmaps support can be handled using solution presented here: http://stackoverflow.com/a/10540106/237232 – Dragan Marjanović Dec 13 '12 at 16:39
  • Ran the installer on OS X, 10.8.2, i7 MBPr. Crashes the system when an AVD tries to boot using Intel image. Found this note about incompatibility: http://software.intel.com/en-us/forums/topic/335810 – Robert Karl Jan 29 '13 at 19:30
  • OSX 1.8.2 look for dmg file and install. Works great here (hackintosh though) – George Mar 16 '13 at 16:14
  • 6
    @Robert Karl There's a know issue on Mac OS X 10.8.2 that caused a Kernel Panic for me when I ran HAXM. Intel has a patch that fixes the issue you download it here: http://software.intel.com/en-us/articles/intel-hardware-accelerated-execution-manager Then open patched dmg file and follow the instructions. – JosephL Apr 04 '13 at 01:58
  • I get a kernel panic when running at some point: Kernel panic - not syncing: Attempted to kill init!. I am on window 7x64 - cpu supports virtualization. I tried installing haxm both from sdk manager and intel web site. What to do? – Radu Simionescu Jun 19 '13 at 07:25
  • I've enabled the "vt" in bios setting and then installed the intel haxm. Now my emulator starts but android doesn't boot and emulator keeps black. What's the problem? (windows 7-64bit, 4gig RAM, eclipse) – Alireza Farahani Jan 10 '14 at 18:08
  • If you got freezes and crashes running it on a Mac with Mavericks, try using this hotfix from Intel (1.0.7) http://software.intel.com/en-us/android/articles/intel-hardware-accelerated-execution-manager – Oliver Drummond Jan 28 '14 at 16:43
  • 1
    I enabled Virtualization in my BIOS and this is my [Intel Processor](http://ark.intel.com/products/47663/Intel-Core-i3-330M-Processor-3M-Cache-2_13-GHz?q=330m) but when i want to install the HAXM, get the error that says: **This computer does not support Intel Virtualization Technology (VT-x). HAXM cannot be installed. Please refer to the Intel HAXM documentation for more information.** – Rasool Ghafari Feb 23 '14 at 10:10
  • The OS X Mavericks issue is discussed on stackoverflow here: http://stackoverflow.com/questions/19243490/android-emulator-freezing-osx-10-9-mavericks-with-haxm – ThomasW Mar 20 '14 at 09:34
  • 3
    Note to Windows 8.1 Users: You must disable Hyper-V otherwise installer will think that VT-x is not available. – jM2.me Mar 28 '14 at 15:48
  • Ugh. Figures. My local machine has AMD processors and the available remote Intel based machine is running VMWare so it won't install there either! – Brian Knoblauch Jun 18 '14 at 15:23
  • @jM2.me how do you disable it? – android developer Jul 07 '14 at 17:04
  • 1
    @androiddeveloper This is how you can disable the Hyper-V after which you need to restart your system so that the system can configure those features, http://www.eightforums.com/tutorials/42041-hyper-v-enable-disable-windows-8-a.html – Himanshu Aggarwal Aug 01 '14 at 18:16
  • 1
    If anyone is having a problem that the screen of AVD is persistently black, then check the "Use Host GPU" checkbox while creating/editing the AVD. – Himanshu Aggarwal Aug 01 '14 at 18:36
  • 1
    @HimanshuAggarwal Thank you . It took a long time to disable it, and the driver finally successfully finished installing. I wonder if that was the whole reason for why it didn't work. Anyway, I've made a new emulator that uses the Intel image, and... it's faster but it also has weird issues like not responding to events on time, but in terms of performance , it's about as fast as my device, if you try out Antutu benchmark. – android developer Aug 01 '14 at 21:12
  • @HimanshuAggarwal However, if I use the old 2.3 emulator , it's still very slow. only newer ones work well. – android developer Aug 02 '14 at 23:05
  • Thanks! I now see "HAX is working and emulator runs in fast virt mode" :-D – asgs Sep 24 '14 at 01:29
  • @jM2.me wat? What is 'Hyper-V' and how do we disable it? – Don Cheadle Aug 15 '15 at 20:16
24

Small Note for Windows 8 user, Intel HAX will not work if Hyper-V feature is enable. Hyper-V (like most of the virtualization tech) will exclusively lock the VT extension witch will prevent HAX to work properly. A workaround if you “need” Hyper-V too might be to stop manually the Hyper-V services when you need HAX (haven’t tested it yet through).

VeV
  • 1,200
  • 12
  • 20
21

If all else fails. Simply try to download the Intel HAXM zip manually, extract and install. check here

Remember this only works for an Intel cpu that supports Intel Virtualization Technology. And you MUST enable virtulization in your bios.

It's a fairly decent and very noticeable improvement to the android emulator if you ask me.

swiftBoy
  • 33,793
  • 26
  • 129
  • 124
akimsko
  • 884
  • 6
  • 7
  • installed it in the past . no luck . btw , it was enabled in the BIOS , so still i don't understand why it's not as speedy as google has promised. – android developer Jun 12 '12 at 13:29
  • @androiddeveloper It really works !!! When you installed HAXM how much RAM did you allocate ? I allocated 512 MB and its blazingly fast ! – GoodSp33d May 03 '13 at 04:28
  • @2-Stroker after downloading the new driver (updated recently) i've tried to install it and it says that my computer doesn't support intel virtualization technology. guess i will never have a smooth emulator with my current computer. :( maybe i will try it at the office. – android developer May 03 '13 at 06:30
18

Not every processor is supporting the virtualization!

To find out your chipset abilities go to http://ark.intel.com/, insert the name of your processor in the search line and check out the resolve.

Advanced Technologies: ...

Intel® Virtualization Technology (VT-x) = ???

If you see "No", you can forget HAXM!

Community
  • 1
  • 1
Gimix
  • 181
  • 1
  • 2
9

Here are the steps to get the Hardware Accelerated Execution (HAX) which is really quite a lot:

1-check your processor Intel website to see if it supports Intel VT-x or not: http://ark.intel.com/Products/VirtualizationTechnology all Intel Core i processors and some other selected processors support Intel VT-x

2- check your bios to enable Intel VT-x , usually called hardware virtualization or Intel virtualization in bios

3- check if you are using a software conflicting with HAXM, popular software conflicting with haxm include but not limited to:

Hyper-V
Windows phone SDK 8
Avast antivirus 8 

4-install Intel management engine interface (MEI), this driver is usually not installed and is not part of retailer Windows DVD, even Windows 8. Check this post about how to install: http://communities.intel.com/community/vproexpert/blog/2011/12/19/mei-driver-now-available-via-microsoft-windows-update This driver is required and is not optional to activate Hardware Acceleration you can also install it from windows update

5-use android SDK manager to download Extras -> Intel x86 Hardware Accelerated Execution Manager.

6-Run installer of HAXM from: [Android SDK Root]\extras\intel\Hardware_Accelerated_Execution_Manager\IntelHaxm.exe

if you passed the previous steps the installer will work just fine ,otherwise it will fail

7-start AVD and see the difference in performance, Animations are faster System UI and launchers crashes in 4.0.3 but are just fine for 4.2.2

see installation guide by intel:

Muhammad Annaqeeb
  • 6,038
  • 3
  • 32
  • 39
  • Thanks! I had incorrectly assumed the SDK Manager would auto install the HAXM package instead of just downloading it. Step 6 solved it for me. – zim2411 Aug 19 '13 at 15:26
  • Thanks For Information , Is There any other ways to launch android projects without using previous way , Coz my intel don't support the VT-x @MuhammadAnnaqeeb – Loai Jan 05 '15 at 17:55
  • @Loai Of course you can run it without HAX. HAX is used only to speed up x86 emulation, not to enable it, and it does not speed up ARM emulation. Also if you have an android device you can debug your applications on the device itself, by connecting it to the computer, much faster than any accelerated emulator! – Muhammad Annaqeeb Jan 06 '15 at 09:07
  • @MuhammadAnnaqeeb ok , as you said the HAX used to speed up the x86 emulations! , actually when i want to run my project through VM it ask me to install the HAX ! – Loai Jan 06 '15 at 10:41
  • @Loai How does it ask you? Could you post a screenshot of that please? How long do you wait for emulator to launch after that before cancelling the launch? Do you launch ARM emulator without errors? – Muhammad Annaqeeb Jan 06 '15 at 11:31
7

Using SDK Manager to download Intel HAX did not work.

Downloading and installing it from the Intel website did work. http://software.intel.com/en-us/articles/intel-hardware-accelerated-execution-manager/

Top Tip: making the change in my BIOS to enable virtualization and then using "restart" did not enable virtualization. Doing a cold boot (i.e. shutdown and restart) suddenly made it appear.

The first step (on Windows) is to make sure that the Micrsoft Hardware-Assisted Virtualization Tool reports that "this computer is configured with hardware-assisted virtualization". http://www.microsoft.com/en-us/download/details.aspx?id=592

pajb
  • 71
  • 1
  • 1
5

You might need to turn on virtualization in your BIOS, most manufacturers disable it by default. Intel HAX requires CPU virtualization to be enabled.

Patrick Tescher
  • 3,226
  • 1
  • 15
  • 30
3

The same began to happen to me about one week ago, without apparent reason (99% sure that I didn't upgrade anything); after being able to run the emulator for some time it just stopped working without an apparent reason.

I tried to install the Intel thingie, but the installer reported that my machine doesn't support Intel VM, despite the fact that it has an Intel i3 processor and that virtualization is enabled (perhaps XP is too old an OS for that, although MS VM, Oracle's Virtual Box and VMWare have been installed an working in this machine with the same OS).

I just edited the VD to emulate an Arm processor, and everything is working again.

Perhaps not the optimal solution, but it works!

3

For Windows, there are some answers explained how it works. But I'm a Mac User, I don't know how to install HAX driver for Mac as they did for Windows. Finally I found the below link and it did fix my problem. You should download HAXM of Mac and then install it.

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

Jagger
  • 1,669
  • 2
  • 11
  • 11
  • I don't use a Mac. However, I wonder, did it help? is it (the emulator) as fast as you'd hope it'd be? is it at least smooth? How did installing the driver help compared to without it? – android developer May 01 '14 at 05:23
2

Complete step-by-step instructions for running the accelerated emulator can be found on the official Android developers website:

Caution: As of SDK Tools Revision 17, the virtual machine acceleration feature for the emulator is experimental; be alert for incompatibilities and errors when using this feature.

Jeff Axelrod
  • 25,625
  • 29
  • 137
  • 239
  • would using windows 8 be a possible cause that it doesn't work well ? also , do you think it could work on ubuntu ? what if ubuntu was installed via Wubi ? – android developer Sep 19 '12 at 20:55
  • @androiddeveloper I suggest you post your comment as a new question. This quote is not from me; it's from the Android developers website linked to in my answer. – Jeff Axelrod Sep 19 '12 at 21:29
  • do you have any experience with either of those questions? also , did you manage to make the new intel emulator work well so that it's much faster than the normal way the emulator works? – android developer Sep 19 '12 at 23:16
  • @androiddeveloper I ran the emulator with virtual machine acceleration (changing to the Intel Atom x86 CPU) and it seemed to take about the same time as the ARM emulator to boot. It seemed slightly more responsive than the ARM emulator, but still nothing like a real device. I didn't do any benchmarks. And no, I don't use Windows 8 or Ubuntu. I use Windows 7 x64--I wasn't aware of a Windows 8 being available. – Jeff Axelrod Sep 20 '12 at 00:53
  • so it's still not as fast as shown in google's videos . too bad. – android developer Sep 20 '12 at 05:58
  • @androiddeveloper I didn't take a look at their videos. While the speed of application execution doesn't seem too much faster, I have noticed that starting from Eclipse seems faster and debugging/stepping through source does seem noticeably more responsive. I would have expected the increase to be the other way around--faster execution vs. not much difference debugging. – Jeff Axelrod Sep 24 '12 at 17:52
2

You have to download the Intel® Hardware Accelerated Execution Manager. Then you will get this message:

Starting emulator for AVD 'test' emulator: device fd:740 HAX is working and emulator runs in fast virt mode

KRP
  • 294
  • 7
  • 22
gderaco
  • 2,132
  • 1
  • 12
  • 18
  • others have answered a similar thing. it's just that it appears my computer can't support it, even though it's not that old and should be capable to run android smoothly. the proof is that it can run fine using virtualBox. – android developer Sep 05 '13 at 21:49
  • I had your same issue, I just installed the manager and now works correctly – gderaco Sep 05 '13 at 22:14
  • well i can't install using the link you've written. – android developer Sep 05 '13 at 23:27
  • 1
    i get the same as on this post: http://stackoverflow.com/a/10772162/878126 , meaning: "this computer does not support intel virtualization technology (VT-x). HAXM cannot be installed. Please refer to the Intel HAXM documentation for more information." . – android developer Sep 06 '13 at 07:10
  • then there's no way, you would have to change hardware to run it – gderaco Sep 06 '13 at 13:59
  • yes i know. it's just weird since the bios says that it has virtualization, and it's enabled. also, the computer isn't that old. i don't get what's the point of making the emulator work fine only if you have this component. any decent computer from the last 5 years should be able to run android just fine... – android developer Sep 06 '13 at 20:20
2

For Mac users who want to check whether your processor supports virtualisation, use the maccpuid software and look for VMX. If it is checked then you're good to go.

Download it here

VMX checked is a sign that your processor support virtualisation asked

Peter Mortensen
  • 28,342
  • 21
  • 95
  • 123
Windo
  • 1,356
  • 1
  • 11
  • 8
1

Here there are two issues we have to concentrate on:

  1. HAX device failed to open,

    For this problem, you have to run the HAX device setup file from the HAX addon folder. Follow Speed Up Android Emulator to know clearly how.

  2. If you created the AVD through AVD manager then you can change the RAM size in AVD Manager and device edit option.

If you created the AVD through command line, then you should start the AVD from command line will work,

emulator -memory 512 -avd gtv_avd
Peter Mortensen
  • 28,342
  • 21
  • 95
  • 123
Kartihkraj Duraisamy
  • 2,871
  • 2
  • 22
  • 36
0

If everything else fails, it's good to try my option and download a HAXM installer.

It needs to be copied to HAXM installation folder and then started from command line (start CMD as an Administrator). After restarting computer HAXM will be installed. It perfectly worked for me as I was having problems with installing it on my laptop.

After all simply type sc query intelhaxm in your cmd in order to check whether HAXM is installed properly.

KRP
  • 294
  • 7
  • 22
TheOpti
  • 1,561
  • 2
  • 19
  • 35
0

If you are running an Intel processor make sure the HAXM (Intel® Hardware Accelerated Execution Manager) installer is installed via SDK Manager by checking this option in SDK Manager. And then run the HAXM installer ext via the path below.

your_sdk_folder\extras\intel\Hardware_Accelerated_Execution_Manager\intelhaxm.exe

Also check the RAM size allocated while doing HAX installation so it fits the RAM size of your emulator.

This video shows all the required steps which may help you to solve the problem.

This video will also help you if you face a problem after installing HAXM.

Peter Mortensen
  • 28,342
  • 21
  • 95
  • 123
Yogesh patel
  • 1,301
  • 2
  • 15
  • 21
0
  1. Download HAXM from the Intel site.

  2. Install it.

  3. And then run the AVD from AndroidStudio, menu -> Tools -> AVD. Choose x86.

It works!

Peter Mortensen
  • 28,342
  • 21
  • 95
  • 123