Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

/dev/kvm not found on mac

So I've been working with android studio 2.0 beta on my Mac and AVD was working fine.

But then I notice that android studio can't launch AVD now. It says /dev/kvm not found. enable VT-x in your bios security settings, ensure that your linux distro has working kvm module.

enter image description here

The thing is: I didn't touch bios settings at all. Possible causes :

  • VMWare - I was playing with virtual machines and configuring new networks for vm's just before I noticed the error.
  • CleanMyMac - I also used this app to clean the system
  • other causes are possible, but I never entered BIOS or touched system settings

The solutions on resolving this issue I found all refer to Linux, rather than Mac. How would I fix this?

EDIT:

I reinstalled OS X (without formatting hard drive). That didn't work.

like image 404
Oleg Filimonov Avatar asked Mar 31 '16 06:03

Oleg Filimonov


Video Answer


1 Answers

Here is the solution that worked me.

Well, Android Studio need HAXM to run emulator.

The issue is that the HAXM drivers doesn’t support the beta version of Mac Os High Serria yet.

The driver works but with a little bit of additional command.

First, you will need to disable the Security Protection on kext. The drivers is not sign for this version.

From https://apple.stackexchange.com/a/269777:

  1. Get into Recovery Mode by restarting and holding down ⌘+R until Apple logo appears.
  2. In the top menu click Utilities > Terminal.
  3. In the Terminal window type and press Enter:

    csrutil enable --without kext

  4. Then restart the Mac.

Then you can install HAXM from:

Download the driver from here https://software.intel.com/en-us/android/articles/intel-hardware-accelerated-execution-manager/ and unzip it.

Open a terminal and go to the directory of the driver :

cd Downloads/haxm-macosx_v6_2_0
# edit the file and look for 10.12
nano silent_install.sh
CTRL + W
10.12

Add 10.13 after 10.12, and save the file ( CTRL+X, Y, ENTER)

Run it:

./silent_install.sh

To be sure it works:

sudo kextload -bundle-id com.intel.kext.intelhaxm

Now your emulator should work !

like image 84
vinsentos Avatar answered Oct 21 '22 02:10

vinsentos