Fixed
Status Update
Comments
al...@gmail.com <al...@gmail.com> #2
The issue is that Jetifier modifies jars and does not remove signatures. Below is the original class:
Classfile /tmp/non-jetified/org/bouncycastle/jce/provider/ExtCRLException.class
Last modified Mar 1, 2015; size 362 bytes
MD5 checksum 3968a716f9e60e1ad36c34157bd0239f
class org.bouncycastle.jce.provider.ExtCRLException extends java.security.cert.CRLException
minor version: 0
major version: 49
flags: ACC_SUPER
Constant pool:
#1 = Utf8 <init>
#2 = Utf8 cause
#3 = Utf8 getCause
#4 = Utf8 java/security/cert/CRLException
#5 = Utf8 org/bouncycastle/jce/provider/ExtCRLException
#6 = Class #4 // java/security/cert/CRLException
#7 = Class #5 // org/bouncycastle/jce/provider/ExtCRLException
#8 = Utf8 Ljava/lang/Throwable;
#9 = Utf8 (Ljava/lang/String;)V
#10 = Utf8 ()Ljava/lang/Throwable;
#11 = Utf8 (Ljava/lang/String;Ljava/lang/Throwable;)V
#12 = NameAndType #2:#8 // cause:Ljava/lang/Throwable;
#13 = NameAndType #1:#9 // "<init>":(Ljava/lang/String;)V
#14 = Fieldref #7.#12 // org/bouncycastle/jce/provider/ExtCRLException.cause:Ljava/lang/Throwable;
#15 = Methodref #6.#13 // java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
#16 = Utf8 Code
{
java.lang.Throwable cause;
descriptor: Ljava/lang/Throwable;
flags:
org.bouncycastle.jce.provider.ExtCRLException(java.lang.String, java.lang.Throwable);
descriptor: (Ljava/lang/String;Ljava/lang/Throwable;)V
flags:
Code:
stack=2, locals=3, args_size=3
0: aload_0
1: aload_1
2: invokespecial #15 // Method java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
5: aload_0
6: aload_2
7: putfield #14 // Field cause:Ljava/lang/Throwable;
10: return
public java.lang.Throwable getCause();
descriptor: ()Ljava/lang/Throwable;
flags: ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
0: aload_0
1: getfield #14 // Field cause:Ljava/lang/Throwable;
4: areturn
}
One processed with Jetifier:
Classfile /tmp/jetified/org/bouncycastle/jce/provider/ExtCRLException.class
Last modified Oct 14, 2019; size 362 bytes
MD5 checksum 76bc557706ee3480e53d88b21316913f
class org.bouncycastle.jce.provider.ExtCRLException extends java.security.cert.CRLException
minor version: 0
major version: 49
flags: ACC_SUPER
Constant pool:
#1 = Utf8 org/bouncycastle/jce/provider/ExtCRLException
#2 = Class #1 // org/bouncycastle/jce/provider/ExtCRLException
#3 = Utf8 java/security/cert/CRLException
#4 = Class #3 // java/security/cert/CRLException
#5 = Utf8 cause
#6 = Utf8 Ljava/lang/Throwable;
#7 = Utf8 <init>
#8 = Utf8 (Ljava/lang/String;Ljava/lang/Throwable;)V
#9 = Utf8 (Ljava/lang/String;)V
#10 = NameAndType #7:#9 // "<init>":(Ljava/lang/String;)V
#11 = Methodref #4.#10 // java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
#12 = NameAndType #5:#6 // cause:Ljava/lang/Throwable;
#13 = Fieldref #2.#12 // org/bouncycastle/jce/provider/ExtCRLException.cause:Ljava/lang/Throwable;
#14 = Utf8 getCause
#15 = Utf8 ()Ljava/lang/Throwable;
#16 = Utf8 Code
{
java.lang.Throwable cause;
descriptor: Ljava/lang/Throwable;
flags:
org.bouncycastle.jce.provider.ExtCRLException(java.lang.String, java.lang.Throwable);
descriptor: (Ljava/lang/String;Ljava/lang/Throwable;)V
flags:
Code:
stack=2, locals=3, args_size=3
0: aload_0
1: aload_1
2: invokespecial #11 // Method java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
5: aload_0
6: aload_2
7: putfield #13 // Field cause:Ljava/lang/Throwable;
10: return
public java.lang.Throwable getCause();
descriptor: ()Ljava/lang/Throwable;
flags: ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
0: aload_0
1: getfield #13 // Field cause:Ljava/lang/Throwable;
4: areturn
}
Changes in the constants pool cause changes in the code (indices change), which causes different MD5 checksums. This means that signatures will not match any more.
This started happening in 3.6.0-beta01 because we are using Jetifier with copyUnmodifiedLibsAlso=true flag (previously it was false).
Classfile /tmp/non-jetified/org/bouncycastle/jce/provider/ExtCRLException.class
Last modified Mar 1, 2015; size 362 bytes
MD5 checksum 3968a716f9e60e1ad36c34157bd0239f
class org.bouncycastle.jce.provider.ExtCRLException extends java.security.cert.CRLException
minor version: 0
major version: 49
flags: ACC_SUPER
Constant pool:
#1 = Utf8 <init>
#2 = Utf8 cause
#3 = Utf8 getCause
#4 = Utf8 java/security/cert/CRLException
#5 = Utf8 org/bouncycastle/jce/provider/ExtCRLException
#6 = Class #4 // java/security/cert/CRLException
#7 = Class #5 // org/bouncycastle/jce/provider/ExtCRLException
#8 = Utf8 Ljava/lang/Throwable;
#9 = Utf8 (Ljava/lang/String;)V
#10 = Utf8 ()Ljava/lang/Throwable;
#11 = Utf8 (Ljava/lang/String;Ljava/lang/Throwable;)V
#12 = NameAndType #2:#8 // cause:Ljava/lang/Throwable;
#13 = NameAndType #1:#9 // "<init>":(Ljava/lang/String;)V
#14 = Fieldref #7.#12 // org/bouncycastle/jce/provider/ExtCRLException.cause:Ljava/lang/Throwable;
#15 = Methodref #6.#13 // java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
#16 = Utf8 Code
{
java.lang.Throwable cause;
descriptor: Ljava/lang/Throwable;
flags:
org.bouncycastle.jce.provider.ExtCRLException(java.lang.String, java.lang.Throwable);
descriptor: (Ljava/lang/String;Ljava/lang/Throwable;)V
flags:
Code:
stack=2, locals=3, args_size=3
0: aload_0
1: aload_1
2: invokespecial #15 // Method java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
5: aload_0
6: aload_2
7: putfield #14 // Field cause:Ljava/lang/Throwable;
10: return
public java.lang.Throwable getCause();
descriptor: ()Ljava/lang/Throwable;
flags: ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
0: aload_0
1: getfield #14 // Field cause:Ljava/lang/Throwable;
4: areturn
}
One processed with Jetifier:
Classfile /tmp/jetified/org/bouncycastle/jce/provider/ExtCRLException.class
Last modified Oct 14, 2019; size 362 bytes
MD5 checksum 76bc557706ee3480e53d88b21316913f
class org.bouncycastle.jce.provider.ExtCRLException extends java.security.cert.CRLException
minor version: 0
major version: 49
flags: ACC_SUPER
Constant pool:
#1 = Utf8 org/bouncycastle/jce/provider/ExtCRLException
#2 = Class #1 // org/bouncycastle/jce/provider/ExtCRLException
#3 = Utf8 java/security/cert/CRLException
#4 = Class #3 // java/security/cert/CRLException
#5 = Utf8 cause
#6 = Utf8 Ljava/lang/Throwable;
#7 = Utf8 <init>
#8 = Utf8 (Ljava/lang/String;Ljava/lang/Throwable;)V
#9 = Utf8 (Ljava/lang/String;)V
#10 = NameAndType #7:#9 // "<init>":(Ljava/lang/String;)V
#11 = Methodref #4.#10 // java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
#12 = NameAndType #5:#6 // cause:Ljava/lang/Throwable;
#13 = Fieldref #2.#12 // org/bouncycastle/jce/provider/ExtCRLException.cause:Ljava/lang/Throwable;
#14 = Utf8 getCause
#15 = Utf8 ()Ljava/lang/Throwable;
#16 = Utf8 Code
{
java.lang.Throwable cause;
descriptor: Ljava/lang/Throwable;
flags:
org.bouncycastle.jce.provider.ExtCRLException(java.lang.String, java.lang.Throwable);
descriptor: (Ljava/lang/String;Ljava/lang/Throwable;)V
flags:
Code:
stack=2, locals=3, args_size=3
0: aload_0
1: aload_1
2: invokespecial #11 // Method java/security/cert/CRLException."<init>":(Ljava/lang/String;)V
5: aload_0
6: aload_2
7: putfield #13 // Field cause:Ljava/lang/Throwable;
10: return
public java.lang.Throwable getCause();
descriptor: ()Ljava/lang/Throwable;
flags: ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
0: aload_0
1: getfield #13 // Field cause:Ljava/lang/Throwable;
4: areturn
}
Changes in the constants pool cause changes in the code (indices change), which causes different MD5 checksums. This means that signatures will not match any more.
This started happening in 3.6.0-beta01 because we are using Jetifier with copyUnmodifiedLibsAlso=true flag (previously it was false).
pi...@gmail.com <pi...@gmail.com> #3
@Chris You can work around this by updating gradle.properties with:
android.jetifier.blacklist=.*bcprov.*
This will avoid Jetifying the bouncycastle library.
android.jetifier.blacklist=.*bcprov.*
This will avoid Jetifying the bouncycastle library.
hu...@google.com <hu...@google.com>
m4...@gmail.com <m4...@gmail.com> #4
Thanks Ivan!
si...@gmail.com <si...@gmail.com> #6
did this fix make it in for 3.6?
lf...@google.com <lf...@google.com> #7
Jetifier 1.0.0-beta08 was released and has a fix for this.
To avoid waiting for new Android Studio you can workaround this in the meantime by forcing usage of a new version of jetifier in gradle:
buildscript {
dependencies {
classpath 'com.android.tools.build:gradle:x.y.z'
classpath 'com.android.tools.build.jetifier:jetifier-processor:1.0.0-beta08' // <- Add this
}
}
To avoid waiting for new Android Studio you can workaround this in the meantime by forcing usage of a new version of jetifier in gradle:
buildscript {
dependencies {
classpath 'com.android.tools.build:gradle:x.y.z'
classpath 'com.android.tools.build.jetifier:jetifier-processor:1.0.0-beta08' // <- Add this
}
}
lf...@google.com <lf...@google.com> #8
ma...@gmail.com <ma...@gmail.com> #9
Worked perfect, thanks
jo...@gtempaccount.com <jo...@gtempaccount.com> #10
Thanks, Frank. Life is good again!
hs...@google.com <hs...@google.com> #11
A further investigation from google side revealed something abnormal with the device file created by Intel HAXM. It is expected that HAXM will create a device file representing VMs under "/dev/hax_vm/vmXX" where XX is VM ID. However, on high sierra, the device file created is put under "/dev/hax*/vmXX". The "*" here definitely suggests something unusual, which is not a typical file or directory name. Since there should be changes to HAXM binary so far, High Sierra should be changing something that HAXM should be adapted to.
Hope this could be a hint for Yu Ning for further investigation.
Hope this could be a hint for Yu Ning for further investigation.
ra...@gmail.com <ra...@gmail.com> #12
Could you please provide some step-by-step instructions on how to enable Hypervisor.Framework? Adding "HVF = on" in ~/.android/advancedFeatures.ini didn't have any effect for me, I'm still getting "failed to initialize HAX: Invalid argument"...
lf...@google.com <lf...@google.com> #13
That's weird, can you supply the faulting AVD's config.ini?
You'll need to run it on a 32-bit x86 AVD, as we don't support running Hypervisor.Framework on 64-bit x86 AVD's currently.
Here is what I do:
1. Go to AVD Manager
2. Create a new AVD (API level 25 or 26 recommended):
a. "Create Virtual Device" > "Next" (Nexus 5X should be selected)
b. Image description: should be "Android 7.1.1" or "Android API 26" images in there that are not grayed out; if not, click the "Download" link and try the process again.
c. Make sure it is a x86 (not x86_64) image.
3. Finish the AVD creation process (Default settings should work)
4. Start the AVD (hit the "play" button on the AVD manager for the AVD you just created).
You'll need to run it on a 32-bit x86 AVD, as we don't support running Hypervisor.Framework on 64-bit x86 AVD's currently.
Here is what I do:
1. Go to AVD Manager
2. Create a new AVD (API level 25 or 26 recommended):
a. "Create Virtual Device" > "Next" (Nexus 5X should be selected)
b. Image description: should be "Android 7.1.1" or "Android API 26" images in there that are not grayed out; if not, click the "Download" link and try the process again.
c. Make sure it is a x86 (not x86_64) image.
3. Finish the AVD creation process (Default settings should work)
4. Start the AVD (hit the "play" button on the AVD manager for the AVD you just created).
ch...@gmail.com <ch...@gmail.com> #14
Thanks, it works for me:
put the text "HVF = on" in ~/.android/advancedFeatures.ini (create this file if it doesn't exist already).
put the text "HVF = on" in ~/.android/advancedFeatures.ini (create this file if it doesn't exist already).
[Deleted User] <[Deleted User]> #15
I'm from HAXM team, Yu and i have discussed this issue, and i think we have came up with a solution for it. new HAXM will be release after fixing it.
Thanks!
Thanks!
ra...@gmail.com <ra...@gmail.com> #16
That's good news, because I can't get HVF to work. It's as if the entry in advancedFeatures.ini was ignored.
~$ cat .android/advancedFeatures.ini
HVF = on
~$ Library/Android/sdk/tools/emulator -version
Android emulator version 26.1.2.0 (build_id 4077558) (CL:500db745bd44dbc6000413b5e8969d83216ff7cd)
~$ Library/Android/sdk/tools/emulator @Nexus_5X_API_26
emulator: ERROR: x86 emulation currently requires hardware acceleration!
Please ensure Intel HAXM is properly installed and usable.
CPU acceleration status: HAXM is not installed on this machine
Exactly the same output with HVF = off.
Using Android Studio 3.0 Canary 5
~$ cat .android/advancedFeatures.ini
HVF = on
~$ Library/Android/sdk/tools/emulator -version
Android emulator version 26.1.2.0 (build_id 4077558) (CL:500db745bd44dbc6000413b5e8969d83216ff7cd)
~$ Library/Android/sdk/tools/emulator @Nexus_5X_API_26
emulator: ERROR: x86 emulation currently requires hardware acceleration!
Please ensure Intel HAXM is properly installed and usable.
CPU acceleration status: HAXM is not installed on this machine
Exactly the same output with HVF = off.
Using Android Studio 3.0 Canary 5
lf...@google.com <lf...@google.com> #17
Ralf, you might need to first install HAXM in order to get HVF to work. That might involve 1) a trip to $ANDROID_SDK_ROOT/extras/intel and running the installer manually 2) going to Preferences > Security and allowing any recently blocked kernel extension to allow to install, and then running the HAXM installer again.
[Deleted User] <[Deleted User]> #18
We haven't reproduced the issue due to lack of a macOS 10.13 environment, but we investigated the issue today based on information in this thread, especially #11. Our current hypothesis is that macOS 10.13 beta fixes a bug in the XNU (Darwin) kernel, which results in a behavior change in a kernel API used by HAXM for creating VM device nodes (/dev/hax_vm/vm<vm_id>). So HAXM needs to adapt to that.
Details:
1. HAXM driver calls BSD API devfs_make_node() to create /dev/hax_vm/vm<vm_id>. This API requires a path relative to /dev/, so if vm_id = 1, HAXM will pass "hax_vm*/vm01" to it.
2. Why the asterisk? I thought it was an unnecessary wildcard, but if I remove it, on macOS 10.10 (probably <= 10.12), I get /dev/hax_v/vm01 instead, i.e. the XNU implementation of devfs_make_node() "eats" the last character of every subdirectory along the path. It turns out this bug has been around for quite a while:
https://lists.apple.com/archives/darwin-kernel/2007/Dec/msg00072.html
And I believe the culprit is this line in XNU kernel:
https://github.com/opensource-apple/xnu/blob/master/bsd/miscfs/devfs/devfs_tree.c#L331
There's no 10.13 branch in that GitHub project, but my guess is Apple somehow finally decided to fix this bug.
3. We are yet to come up with an elegant solution, but as #15 suggested, we should be able to implement a hack: call the API with an extra character (e.g. '*') first, check if the resulting path contains that extra character, and if so, undo the first call and make a second call without the extra character. We'll try this solution on Monday if there's no better idea.
Details:
1. HAXM driver calls BSD API devfs_make_node() to create /dev/hax_vm/vm<vm_id>. This API requires a path relative to /dev/, so if vm_id = 1, HAXM will pass "hax_vm*/vm01" to it.
2. Why the asterisk? I thought it was an unnecessary wildcard, but if I remove it, on macOS 10.10 (probably <= 10.12), I get /dev/hax_v/vm01 instead, i.e. the XNU implementation of devfs_make_node() "eats" the last character of every subdirectory along the path. It turns out this bug has been around for quite a while:
And I believe the culprit is this line in XNU kernel:
There's no 10.13 branch in that GitHub project, but my guess is Apple somehow finally decided to fix this bug.
3. We are yet to come up with an elegant solution, but as #15 suggested, we should be able to implement a hack: call the API with an extra character (e.g. '*') first, check if the resulting path contains that extra character, and if so, undo the first call and make a second call without the extra character. We'll try this solution on Monday if there's no better idea.
lf...@google.com <lf...@google.com> #19
Thanks Yu for the detailed report. That's a pretty serious bug that would break a bunch of other kernel exts as well, hmm. The mailing list discussion seems to discourage creating things in /dev/; would there be a way to get HAXM to be in another directory and have it work across all versions then?
Also, Is it possible to also trigger the fixed name from how the emulator uses HAXM ioctls?
Also, Is it possible to also trigger the fixed name from how the emulator uses HAXM ioctls?
hs...@google.com <hs...@google.com> #20
Maybe HAXM can borrow the way KVM works. When asked for creating a VM, KVM returned file handle directly by the creation ioctl. Right now, HAXM needs two steps. A creation ioctl and an open call to get that handle.
However, it depends on whether MacOS offers the needed APIs or not.
However, it depends on whether MacOS offers the needed APIs or not.
hs...@google.com <hs...@google.com> #21
The above suggestion does make an API change which means QEMU needs to be modified based on HAXM version, if the suggestion is viable.
ra...@gmail.com <ra...@gmail.com> #22
Frank, I had HAXM installed and HVM didn't work, that's why I then retried after uninstalling HAXM (and removing the kext). Now I installed HAXM again as you suggested (except that I didn't have to do any changes in Preferences > Security). HVM still doesn't work, and no matter whether HVM = on or HVM = off, I still get that "failed to initialize HAX: Invalid argument" error... No idea what I could be doing wrong, I'm editing the file via "vi ~/.android/advancedFeatures.ini" but it just doesn't make any difference what I put in there.
[Deleted User] <[Deleted User]> #23
Could anyone running macOS 10.13 beta do me a favor? If you could just post the output of "uname -v", that would help a lot.
For example, on macOS 10.11:
$ uname -v
Darwin Kernel Version 15.6.0: Tue Apr 11 16:00:51 PDT 2017; root:xnu-3248.60.11.5.3~1/RELEASE_X86_64
I guess the kernel version of macOS 10.13 should begin with 17, but I just want to confirm that.
For example, on macOS 10.11:
$ uname -v
Darwin Kernel Version 15.6.0: Tue Apr 11 16:00:51 PDT 2017; root:xnu-3248.60.11.5.3~1/RELEASE_X86_64
I guess the kernel version of macOS 10.13 should begin with 17, but I just want to confirm that.
ra...@gmail.com <ra...@gmail.com> #24
$ uname -v
Darwin Kernel Version 17.0.0: Tue Jun 13 21:06:15 PDT 2017; root:xnu-4481.0.0.1.1~1/RELEASE_X86_64
Darwin Kernel Version 17.0.0: Tue Jun 13 21:06:15 PDT 2017; root:xnu-4481.0.0.1.1~1/RELEASE_X86_64
ra...@gmail.com <ra...@gmail.com> #25
I've been testing the 10.13 beta and the HVF workaround on a Late 2009 iMac. Turns out the CPU doesn't support HVF, I suppose that's the reason for the trouble I've been encountering:
$ sysctl kern.hv_support
kern.hv_support: 0
$ sysctl kern.hv_support
kern.hv_support: 0
[Deleted User] <[Deleted User]> #26
#25: Your CPU is probably missing an Intel Virtualization Technology feature called EPT. HAXM should work without EPT, but the performance would not be great.
And thanks for the information, with which I've implemented a patch. Note that I didn't take the approach proposed in #18, because usual file APIs such as open(), close(), etc. are for use by userspace and have side effects when used on device nodes.
Instead, I came up with another hack, which is to detect the macOS (XNU kernel) version HAXM is running on, and adjust the devfs path accordingly. The assumption is that XNU kernels >= 17.0.0 do NOT require an extra character to be appended to every subdirectory name.
I'm hopeful that this will make HAXM compatible with macOS 10.13 beta. But there's no guarantee it will not break again in the future... After all, the mailing list discussion discourages creating *subdirectories* in /dev (but creating files directly under /dev should be fine). So in the long term, we should flatten the currently hierarchical devfs layout, and make corresponding changes on QEMU side.
#20: That would be neat, but I don't know if Mac provides such APIs. If we are making userspace changes anyway, we should get rid of the devfs subdirectories first.
And thanks for the information, with which I've implemented a patch. Note that I didn't take the approach proposed in #18, because usual file APIs such as open(), close(), etc. are for use by userspace and have side effects when used on device nodes.
Instead, I came up with another hack, which is to detect the macOS (XNU kernel) version HAXM is running on, and adjust the devfs path accordingly. The assumption is that XNU kernels >= 17.0.0 do NOT require an extra character to be appended to every subdirectory name.
I'm hopeful that this will make HAXM compatible with macOS 10.13 beta. But there's no guarantee it will not break again in the future... After all, the mailing list discussion discourages creating *subdirectories* in /dev (but creating files directly under /dev should be fine). So in the long term, we should flatten the currently hierarchical devfs layout, and make corresponding changes on QEMU side.
#20: That would be neat, but I don't know if Mac provides such APIs. If we are making userspace changes anyway, we should get rid of the devfs subdirectories first.
hs...@google.com <hs...@google.com> #27
Thanks for quick update. This is an good option to me, too. Handling host OS API changes based on their version is usual practice.
[Deleted User] <[Deleted User]> #28
#27: Have you tried our HAXM 6.2.0 preview release on macOS 10.13 beta? Does it work?
hs...@google.com <hs...@google.com> #29
QA is testing the new release. He should be able to report back soon.
hs...@google.com <hs...@google.com> #30
I got from our QA. Booting AVD is fine now.
st...@gmail.com <st...@gmail.com> #31
Is there already a link to download HAXM version 6.2.0?
hu...@google.com <hu...@google.com>
mi...@gmail.com <mi...@gmail.com> #33
HAXM 6.2.1 works for me on latest High Sierra 10.13 GM candidate. Thanks.
fi...@gmail.com <fi...@gmail.com> #35
great for me! ;)
[Deleted User] <[Deleted User]> #38
pb...@
I try to this blog but, i hav a problem.
input the "sudo kextload -bundle-id com.intel.kext.intelhaxm"
after this message.
"com.intel.kext.intelhaxm failed to load - (libkern/kext) not found; check the system/kernel logs for errors or try kextutil(8)."
i need your help. plz.
I try to this blog but, i hav a problem.
input the "sudo kextload -bundle-id com.intel.kext.intelhaxm"
after this message.
"com.intel.kext.intelhaxm failed to load - (libkern/kext) not found; check the system/kernel logs for errors or try kextutil(8)."
i need your help. plz.
sr...@gmail.com <sr...@gmail.com> #39
same to me
lf...@google.com <lf...@google.com> #40
#38:
That's likely because HAXM wasn't installed yet. You can check if it is installed by issuing
$ kextstat | grep haxm
145 0 0xffffff7f832d6000 0x1c000 0x1c000 com.intel.kext.intelhaxm (6.2.0) FAD2A80C-AB2D-351F-9314-04E1DEB2F004 <7 5 4 3 1>
and seeing if a line similar to that shows up.
You may also use Hypervisor.Framework if your macOS supports:
$ sysctl kern.hv_support
kern.hv_support: 1
and you use a 32-bit x86 image. (and add "HVF = on" in ~/.android/advancedFeatures.ini (create if it doesn't exist))
That's likely because HAXM wasn't installed yet. You can check if it is installed by issuing
$ kextstat | grep haxm
145 0 0xffffff7f832d6000 0x1c000 0x1c000 com.intel.kext.intelhaxm (6.2.0) FAD2A80C-AB2D-351F-9314-04E1DEB2F004 <7 5 4 3 1>
and seeing if a line similar to that shows up.
You may also use Hypervisor.Framework if your macOS supports:
$ sysctl kern.hv_support
kern.hv_support: 1
and you use a 32-bit x86 image. (and add "HVF = on" in ~/.android/advancedFeatures.ini (create if it doesn't exist))
sr...@gmail.com <sr...@gmail.com> #41
sorry stupid mistake, forgot to do the portion in recovery mode
js...@gmail.com <js...@gmail.com> #42
Is this supposed to be completely fixed? I am running into this issue in a brand new (clean install) instance of High Sierra on a 2015 Macbook Pro. When I try to start my Nexus 5 virtual device with the image "Google APIs Intel Atom (x86)" I get:
Starting emulator for AVD 'NExus5_API_25'
emulator: ERROR: x86 emulation currently requires hardware acceleration!
Please ensure Intel HAXM is properly installed and usable.
CPU acceleration status: HAXM is not installed on this machine (/dev/HAX is missing).
I installed HAXM through the DMG and the silent_install.sh. Here's the log of the silent install:
/dev/disk4 GUID_partition_scheme
/dev/disk4s1 Apple_HFS /Volumes/com_intel_kext_haxm_disc
mpkg_file=/Volumes/com_intel_kext_haxm_disc//IntelHAXM_6.2.1.mpkg
ecx 7ffafbff
edx 2c100800
edx 2c100800
No emulator instance exist!
sed: /Library/Extensions/intelhaxm.kext/Contents/Resources/support.txt: No such file or directory
Intel HAXM: This is a new installation
installer: Package name is Intel(R) Hardware Accelerated Execution Manager
installer: Upgrading at base path /
installer: The upgrade was successful.
"disk4" unmounted.
"disk4" ejected.
HAXM silent installation finished!
*************** Silent installation Pass ! ****************
Running "sudo ./silent_install.sh -v" returns "6.2.1".
Running "sudo ./silent_install.sh -c" returns "VT support -- Yes, NX support -- Yes."
Running "sudo kextload -bundle-id com.intel.kext.intelhaxm" returns:
"com.intel.kext.intelhaxm failed to load - (libkern/kext) system policy prevents loading; check the system/kernel logs for errors or try kextutil(8)."
Do I still have to disable the Security Protection on kext first?
Starting emulator for AVD 'NExus5_API_25'
emulator: ERROR: x86 emulation currently requires hardware acceleration!
Please ensure Intel HAXM is properly installed and usable.
CPU acceleration status: HAXM is not installed on this machine (/dev/HAX is missing).
I installed HAXM through the DMG and the silent_install.sh. Here's the log of the silent install:
/dev/disk4 GUID_partition_scheme
/dev/disk4s1 Apple_HFS /Volumes/com_intel_kext_haxm_disc
mpkg_file=/Volumes/com_intel_kext_haxm_disc//IntelHAXM_6.2.1.mpkg
ecx 7ffafbff
edx 2c100800
edx 2c100800
No emulator instance exist!
sed: /Library/Extensions/intelhaxm.kext/Contents/Resources/support.txt: No such file or directory
Intel HAXM: This is a new installation
installer: Package name is Intel(R) Hardware Accelerated Execution Manager
installer: Upgrading at base path /
installer: The upgrade was successful.
"disk4" unmounted.
"disk4" ejected.
HAXM silent installation finished!
*************** Silent installation Pass ! ****************
Running "sudo ./silent_install.sh -v" returns "6.2.1".
Running "sudo ./silent_install.sh -c" returns "VT support -- Yes, NX support -- Yes."
Running "sudo kextload -bundle-id com.intel.kext.intelhaxm" returns:
"com.intel.kext.intelhaxm failed to load - (libkern/kext) system policy prevents loading; check the system/kernel logs for errors or try kextutil(8)."
Do I still have to disable the Security Protection on kext first?
js...@gmail.com <js...@gmail.com> #44
So, I ended up disabling and the installation and the loading worked. Since I thought this was a problem during installation only I went back and enabled it again only to find out that it stopped working again. I then figured out that in System Preferences > Security & Privacy > General, there was a message “System software from developer xxx was blocked from loading.” with an Allow button. Clicking the allow button enabled HAXM again. Hopefully this is a one time operation and I don't have to do it every time or restart.
[Deleted User] <[Deleted User]> #45
Finally found location of "advancedFeatures.ini" file, for me it was in "/Users/<username>/Library/Android/sdk/emulator/lib" changed "HVF = on" and it works for me.
[Deleted User] <[Deleted User]> #46
sa...@gmail.com <sa...@gmail.com> #47
I am also facing issue with installing HAXM in Mac OS High Sierra, but enabling the Hypervisor.Framework support in advancedFeatures.ini just worked fine for me.
Thanks.
Thanks.
el...@gmail.com <el...@gmail.com> #48
any updates on how to fix it ?
su...@suyashjoshi.com <su...@suyashjoshi.com> #49
I have the same issue, please resolve this ASAP. This is definitely an ugly Intel HAXM bug.
[Deleted User] <[Deleted User]> #50
Sorry for the inconvenience. Did you get a "system extension blocked" warning while installing HAXM either through Android Studio or the official, standalone installer? #44 has actually provided the correct solution, which is to manually unblock the loading of the HAXM kernel extension (KEXT) via System Preferences > Security & Privacy.
For step-by-step instructions, please refer to the following links for now. These are for other software products that also install a KEXT, and thus have the same problem on macOS High Sierra. The only thing that will appear different from their screenshots is the developer name, which is "Intel Corporation Apps" for HAXM:
(Symantec Endpoint Protection)https://support.symantec.com/en_US/article.TECH247516.html
(ESET Endpoint Security)https://support.eset.com/kb6512/?viewlocale=en_US
Although we could improve the emulator error message, it's impossible for HAXM to unblock its own KEXT automatically, so the user has to go through the above steps after installing HAXM.
For step-by-step instructions, please refer to the following links for now. These are for other software products that also install a KEXT, and thus have the same problem on macOS High Sierra. The only thing that will appear different from their screenshots is the developer name, which is "Intel Corporation Apps" for HAXM:
(Symantec Endpoint Protection)
(ESET Endpoint Security)
Although we could improve the emulator error message, it's impossible for HAXM to unblock its own KEXT automatically, so the user has to go through the above steps after installing HAXM.
ka...@gmail.com <ka...@gmail.com> #51
I am using MacOs High Sierra. I had same HAXM issue when trying to run the emulator. I searched similar topics in StackExchange and here. And my issue is solved finally :) I am writing this comment to summarized my step-by-step solution, it is not my own solution. It is just putting together the suggested solutions and organizing/outlining them:
SOLUTION A - HVF Solution: Running the emulator on Canary channel 26.1.x (API 25/26 recommended) with Hypervisor.Framework (thread #7)
I implemented this solution and it worked. I am using emulator now on macOS High Sierra.
A1 - If HAXM installed in Android Studio, uninstall it;
------ Go to SDK Manager > SDK Tools (or Appearance & Behaviour > System Settings > Android SDK)
------ Uncheck Intel x86 Emulator Accelerator (HAXM Installer) and Apply. This will uninstall HAXM.
A2 - You might need to first install HAXM in order to get HVF to work (thread #17).
------ Install standalone Intel HAXM as a regular .dmg install. Download from here:https://software.intel.com/en-us/articles/intel-hardware-accelerated-execution-manager-intel-haxm
*****https://stackoverflow.com/questions/33025859/haxm-on-os-x-keeps-on-disappearing
***** For any reason, you can uninstall standalone HAXM installation by;
*****---- sudo Library/Extensions/intelhaxm.kext/Contents/Resources/uninstall.sh
*****------- If above not work, try; sudo /System/Library/Extensions/intelhaxm.kext/Contents/Resources/uninstall.sh
A3 - Check whether your macOS supports Hypervisor.Framework or not: (thread #40)
------- $ sysctl kern.hv_support
------- kern.hv_support: 1 (if support =1, if not support = 0) (should support to implement HVF solution)
A4 - Find the file "advancedFeatures.ini". It may be placed in;
------- ~/.android/advancedFeatures.ini (thread #7) ( Users/<username>/.android/advancedFeatures.ini) or
------- /Users/<username>/Library/Android/sdk/emulator/lib/advancedFeatures.ini (thread #45) (I found mine here)
A5 - Open "advancedFeatures.ini" with an editor.
------ Find the line "HVF = off"
------ Change off to on; "HVF = on" (thread #7)
A6 - Restart Android Studio if it is open (Restart the computer if necessary). Create and RUN the emulator :) No more HAXM warnings :)
SOLUTION B - I didn't try this solution but several comments claim that it also worked. (thread #34,35,36,37) You can try this also, follow the instructions from here :
https://blog.celogeek.com/201708/672/android-studio-emulator-haxm-on-mac-os-high-serria-10-13/
If this is not proper a comment in here, sorry. I just want to share summarized complete solution that worked for me and may help others facing the same problem to follow steps more easily. I hope it helps
SOLUTION A - HVF Solution: Running the emulator on Canary channel 26.1.x (API 25/26 recommended) with Hypervisor.Framework (thread #7)
I implemented this solution and it worked. I am using emulator now on macOS High Sierra.
A1 - If HAXM installed in Android Studio, uninstall it;
------ Go to SDK Manager > SDK Tools (or Appearance & Behaviour > System Settings > Android SDK)
------ Uncheck Intel x86 Emulator Accelerator (HAXM Installer) and Apply. This will uninstall HAXM.
A2 - You might need to first install HAXM in order to get HVF to work (thread #17).
------ Install standalone Intel HAXM as a regular .dmg install. Download from here:
*****
***** For any reason, you can uninstall standalone HAXM installation by;
*****---- sudo Library/Extensions/intelhaxm.kext/Contents/Resources/uninstall.sh
*****------- If above not work, try; sudo /System/Library/Extensions/intelhaxm.kext/Contents/Resources/uninstall.sh
A3 - Check whether your macOS supports Hypervisor.Framework or not: (thread #40)
------- $ sysctl kern.hv_support
------- kern.hv_support: 1 (if support =1, if not support = 0) (should support to implement HVF solution)
A4 - Find the file "advancedFeatures.ini". It may be placed in;
------- ~/.android/advancedFeatures.ini (thread #7) ( Users/<username>/.android/advancedFeatures.ini) or
------- /Users/<username>/Library/Android/sdk/emulator/lib/advancedFeatures.ini (thread #45) (I found mine here)
A5 - Open "advancedFeatures.ini" with an editor.
------ Find the line "HVF = off"
------ Change off to on; "HVF = on" (thread #7)
A6 - Restart Android Studio if it is open (Restart the computer if necessary). Create and RUN the emulator :) No more HAXM warnings :)
SOLUTION B - I didn't try this solution but several comments claim that it also worked. (thread #34,35,36,37) You can try this also, follow the instructions from here :
If this is not proper a comment in here, sorry. I just want to share summarized complete solution that worked for me and may help others facing the same problem to follow steps more easily. I hope it helps
de...@gmail.com <de...@gmail.com> #52
Mobile strike DENCHAi1986 google play stroe
st...@gmail.com <st...@gmail.com> #53
Please why do i keep getting this error whenever i want to install android studio on my mac?
Process: studio [794]
Path: /Volumes/VOLUME/Android Studio.app/Contents/MacOS/studio
Identifier: com.google.android.studio
Version: 4.1 (AI-201.8743.12.41.7042882)
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: studio [794]
User ID: 501
Date/Time: 2021-02-19 15:27:39.749 +0100
OS Version: Mac OS X 10.10.5 (14F2511)
Report Version: 11
Anonymous UUID: AD634625-9D55-0777-AF08-959A64935DAA
Time Awake Since Boot: 2600 seconds
Crashed Thread: 0 AppKit Thread Dispatch queue: com.apple.main-thread
Exception Type: EXC_BAD_ACCESS (SIGABRT)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000303030353150
VM Regions Near 0x303030353150:
VM_ALLOCATE 00000007c0b77000-0000000800000000 [ 1.0G] ---/rwx SM=NUL
-->
MALLOC_TINY 00007fea5b400000-00007fea5b800000 [ 4096K] rw-/rwx SM=COW
Application Specific Information:
abort() called
Thread 0 Crashed:: AppKit Thread Dispatch queue: com.apple.main-thread
0 libsystem_kernel.dylib 0x00007fff854ef286 __pthread_kill + 10
1 libsystem_c.dylib 0x00007fff91d109a3 abort + 129
2 libjvm.dylib 0x000000010b2bfeb2 os::abort(bool) + 22
3 libjvm.dylib 0x000000010b3c95ff VMError::report_and_die() + 2151
4 libjvm.dylib 0x000000010b2c444a JVM_handle_bsd_signal + 523
5 libjvm.dylib 0x000000010b2c1dca signalHandler(int, __siginfo*, void*) + 45
6 libsystem_platform.dylib 0x00007fff8a327f1a _sigtramp + 26
7 libsystem_c.dylib 0x00007fff91cb3f72 strlen + 18
8 com.apple.CoreFoundation 0x00007fff8933484c __CFStringAppendFormatCore + 8524
9 com.apple.CoreFoundation 0x00007fff8942a3a0 _CFStringCreateWithFormatAndArgumentsAux2 + 256
10 com.apple.Foundation 0x00007fff90de14e1 -[NSPlaceholderString initWithFormat:locale:arguments:] + 153
11 com.apple.Foundation 0x00007fff90dfaec9 +[NSString stringWithFormat:] + 174
12 com.apple.java.JavaRuntimeSupport 0x00000001215170cc -[JRSInputMethodController currentInputMethodLocale] + 174
13 libawt_lwawt.dylib 0x0000000121577eda __Java_sun_lwawt_macosx_CInputMethod_getNativeLocale_block_invoke + 41
14 com.apple.Foundation 0x00007fff90e69da0 __NSThreadPerformPerform + 293
15 com.apple.CoreFoundation 0x00007fff89376821 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
16 com.apple.CoreFoundation 0x00007fff893689ad __CFRunLoopDoSources0 + 269
17 com.apple.CoreFoundation 0x00007fff89367fdf __CFRunLoopRun + 927
18 com.apple.CoreFoundation 0x00007fff893679f8 CFRunLoopRunSpecific + 296
19 com.apple.HIToolbox 0x00007fff87b3856f RunCurrentEventLoopInMode + 235
20 com.apple.HIToolbox 0x00007fff87b382ea ReceiveNextEventCommon + 431
21 com.apple.HIToolbox 0x00007fff87b3812b _BlockUntilNextEventMatchingListInModeWithFilter + 71
22 com.apple.AppKit 0x00007fff8c5fa8ab _DPSNextEvent + 978
23 com.apple.AppKit 0x00007fff8c5f9e58 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 346
24 libosxapp.dylib 0x00000001216481d5 -[NSApplicationAWT nextEventMatchingMask:untilDate:inMode:dequeue:] + 121
25 com.apple.AppKit 0x00007fff8c5efaf3 -[NSApplication run] + 594
26 libosxapp.dylib 0x000000012164801a +[NSApplicationAWT runAWTLoopWithApp:] + 219
27 libawt_lwawt.dylib 0x000000012159e40b -[AWTStarter starter:] + 856
28 com.apple.Foundation 0x00007fff90e69da0 __NSThreadPerformPerform + 293
29 com.apple.CoreFoundation 0x00007fff89376821 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
30 com.apple.CoreFoundation 0x00007fff893689ad __CFRunLoopDoSources0 + 269
31 com.apple.CoreFoundation 0x00007fff89367fdf __CFRunLoopRun + 927
32 com.apple.CoreFoundation 0x00007fff893679f8 CFRunLoopRunSpecific + 296
33 com.google.android.studio 0x00000001082f7b77 main + 332
34 libdyld.dylib 0x00007fff8d2265c9 start + 1
Thread 1:: Dispatch queue: com.apple.libdispatch-manager
Process: studio [794]
Path: /Volumes/VOLUME/Android Studio.app/Contents/MacOS/studio
Identifier: com.google.android.studio
Version: 4.1 (AI-201.8743.12.41.7042882)
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: studio [794]
User ID: 501
Date/Time: 2021-02-19 15:27:39.749 +0100
OS Version: Mac OS X 10.10.5 (14F2511)
Report Version: 11
Anonymous UUID: AD634625-9D55-0777-AF08-959A64935DAA
Time Awake Since Boot: 2600 seconds
Crashed Thread: 0 AppKit Thread Dispatch queue: com.apple.main-thread
Exception Type: EXC_BAD_ACCESS (SIGABRT)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000303030353150
VM Regions Near 0x303030353150:
VM_ALLOCATE 00000007c0b77000-0000000800000000 [ 1.0G] ---/rwx SM=NUL
-->
MALLOC_TINY 00007fea5b400000-00007fea5b800000 [ 4096K] rw-/rwx SM=COW
Application Specific Information:
abort() called
Thread 0 Crashed:: AppKit Thread Dispatch queue: com.apple.main-thread
0 libsystem_kernel.dylib 0x00007fff854ef286 __pthread_kill + 10
1 libsystem_c.dylib 0x00007fff91d109a3 abort + 129
2 libjvm.dylib 0x000000010b2bfeb2 os::abort(bool) + 22
3 libjvm.dylib 0x000000010b3c95ff VMError::report_and_die() + 2151
4 libjvm.dylib 0x000000010b2c444a JVM_handle_bsd_signal + 523
5 libjvm.dylib 0x000000010b2c1dca signalHandler(int, __siginfo*, void*) + 45
6 libsystem_platform.dylib 0x00007fff8a327f1a _sigtramp + 26
7 libsystem_c.dylib 0x00007fff91cb3f72 strlen + 18
8 com.apple.CoreFoundation 0x00007fff8933484c __CFStringAppendFormatCore + 8524
9 com.apple.CoreFoundation 0x00007fff8942a3a0 _CFStringCreateWithFormatAndArgumentsAux2 + 256
10 com.apple.Foundation 0x00007fff90de14e1 -[NSPlaceholderString initWithFormat:locale:arguments:] + 153
11 com.apple.Foundation 0x00007fff90dfaec9 +[NSString stringWithFormat:] + 174
12 com.apple.java.JavaRuntimeSupport 0x00000001215170cc -[JRSInputMethodController currentInputMethodLocale] + 174
13 libawt_lwawt.dylib 0x0000000121577eda __Java_sun_lwawt_macosx_CInputMethod_getNativeLocale_block_invoke + 41
14 com.apple.Foundation 0x00007fff90e69da0 __NSThreadPerformPerform + 293
15 com.apple.CoreFoundation 0x00007fff89376821 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
16 com.apple.CoreFoundation 0x00007fff893689ad __CFRunLoopDoSources0 + 269
17 com.apple.CoreFoundation 0x00007fff89367fdf __CFRunLoopRun + 927
18 com.apple.CoreFoundation 0x00007fff893679f8 CFRunLoopRunSpecific + 296
19 com.apple.HIToolbox 0x00007fff87b3856f RunCurrentEventLoopInMode + 235
20 com.apple.HIToolbox 0x00007fff87b382ea ReceiveNextEventCommon + 431
21 com.apple.HIToolbox 0x00007fff87b3812b _BlockUntilNextEventMatchingListInModeWithFilter + 71
22 com.apple.AppKit 0x00007fff8c5fa8ab _DPSNextEvent + 978
23 com.apple.AppKit 0x00007fff8c5f9e58 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 346
24 libosxapp.dylib 0x00000001216481d5 -[NSApplicationAWT nextEventMatchingMask:untilDate:inMode:dequeue:] + 121
25 com.apple.AppKit 0x00007fff8c5efaf3 -[NSApplication run] + 594
26 libosxapp.dylib 0x000000012164801a +[NSApplicationAWT runAWTLoopWithApp:] + 219
27 libawt_lwawt.dylib 0x000000012159e40b -[AWTStarter starter:] + 856
28 com.apple.Foundation 0x00007fff90e69da0 __NSThreadPerformPerform + 293
29 com.apple.CoreFoundation 0x00007fff89376821 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
30 com.apple.CoreFoundation 0x00007fff893689ad __CFRunLoopDoSources0 + 269
31 com.apple.CoreFoundation 0x00007fff89367fdf __CFRunLoopRun + 927
32 com.apple.CoreFoundation 0x00007fff893679f8 CFRunLoopRunSpecific + 296
33 com.google.android.studio 0x00000001082f7b77 main + 332
34 libdyld.dylib 0x00007fff8d2265c9 start + 1
Thread 1:: Dispatch queue: com.apple.libdispatch-manager
sh...@gmail.com <sh...@gmail.com> #54
Basic setting I want ...
Description
The errors in the console are:
Emulator: Failed to open vm 7
Emulator: Failed to create HAX VM
Emulator: No accelerator found.
Emulator: failed to initialize HAX: Invalid argument
I'm assuming it's because Mac OS 10.13 isn't supported yet by Intel HAXM.