69

I'm using Ubuntu 14.04. I recently installed Android Studio, but whenever I try to run a Hello World app, I get this error:

/home/praveen/Android/Sdk/tools/emulator -avd Nexus_6_API_21 -netspeed full -netdelay none
emulator: ERROR: x86 emulation currently requires hardware acceleration!
Please ensure KVM is properly installed and usable.
CPU acceleration status: KVM is not installed on this machine (/dev/kvm is missing).
  • maybe u have a 32 bit system ,, try upgrading it n then try ... android emulator also requires 4gb ram and higher . – yunus Nov 18 '17 at 19:20
38

Either your CPU does not support virtualization, or it is disabled in the bios. Go into your bios and see if you can find a setting to enable it.

  • I am having this error on a Mac. Solution isn't applicable to Macs because they have no BIOS. What to do then? – IgorGanapolsky Jul 6 '17 at 13:21
  • 1
    Go into your bios and see if you can find a setting to enable it - What is the process to do that ???? – B.shruti Aug 1 '17 at 5:11
  • How to go into bios? – Riddhi May 9 '18 at 9:11
  • @Riddhi, it depends on your computer. Usually hit DEL or F12 or F1 when it says. – psusi May 9 '18 at 16:04
67

Use the below command to check whether the KVM is installed in the machine or not,

kvm-ok 

Output:

INFO: /dev/kvm exists
KVM acceleration can be used

Output like the below means,

INFO: Your CPU does not support KVM extensions
KVM acceleration can NOT be used

In this scenario need to install KVM using the below command,

sudo apt-get install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils

Hope this helps.

  • 2
    praveen@praveen-Lenovo-B590:~$ kvm-ok INFO: /dev/kvm does not exist HINT: sudo modprobe kvm_intel INFO: For more detailed results, you should run this as root HINT: sudo /usr/sbin/kvm-ok praveen@praveen-Lenovo-B590:~$ – praveen kumar Dec 24 '14 at 14:37
  • 12
    sudo apt-get install cpu-checker for kvm-ok. – Wtower Feb 3 '16 at 10:24
  • @vembutech after executing command kvm-ok I got an output that- "does not exist". So, I've installed it using the above mentioned command. It has been downloaded. Last line is Processing triggers for ureadahead (0.100.0-16) ... now I run the kvm-ok command again. But again it says "does not exist" – Prabs Feb 8 '16 at 12:24
15
HP-EliteBook-820-G1:/opt/android-studio/bin$ sudo /usr/sbin/kvm-ok
INFO: /dev/kvm does not exist
HINT:   sudo modprobe kvm_intel
INFO: Your CPU supports KVM extensions
INFO: KVM (vmx) is disabled by your BIOS
HINT: Enter your BIOS setup and enable Virtualization Technology (VT),
      and then hard poweroff/poweron your system
KVM acceleration can NOT be used

Affter bios setting, I used the following command

sudo modprobe kvm_intel

Now is ok

  • this solution worked perfect for my Ubuntu 14.0 – Tarun Jul 4 '16 at 10:02
  • this fixed it for me on Ubuntu 12.04 64Bit – SpamBot Aug 26 '16 at 14:58
9

Worked on Ubuntu 15.04, Intel's CPU

  1. sudo apt-get install qemu-kvm
  2. Enable Virtualization Technology in BIOS
  3. sudo kvm-ok
4

I had tried the command,

sudo apt-get install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils

but unfortunately it didn't work. Then I changed owner (rohanverma is user in my case) by using,

sudo chown rohanverma:rohanverma -R /dev/kvm

which worked for me.

3

I saw the same error. But I'm running Ubuntu on the VMware. Ubuntu is installed on the VMware. So the steps to resolve the problem is different from pure ubuntu machine. The complains went away with the following steps:

  1. sudo apt install cpu-checker
  2. In VMware, go setting->Processors->Virtualization Engine, check "Virtualize Intel VT-x/EPT or AMD-V/RVI.
  3. sudo kvm-ok
1

Close any other hypervisors before starting Android Studio. I received the same error message when I tried to run an Android Virtual Device and had a Virtual Box VM running at the same time.

  • 1
    This does not really answer the question. If you have a different question, you can ask it by clicking Ask Question. You can also add a bounty to draw more attention to this question once you have enough reputation. - From Review – earthmeLon Jan 28 '17 at 0:37
  • 2
    @earthmeLon I fixed it. – wjandrea Jan 28 '17 at 2:07

protected by Community Nov 18 '17 at 20:17

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.