82

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).
1
  • maybe u have a 32 bit system ,, try upgrading it n then try ... android emulator also requires 4gb ram and higher .
    – yunus
    Nov 18, 2017 at 19:20

7 Answers 7

81

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.

4
  • 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:~$ Dec 24, 2014 at 14:37
  • 24
    sudo apt-get install cpu-checker for kvm-ok.
    – Wtower
    Feb 3, 2016 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, 2016 at 12:24
  • libvirt-bin is no longer used: askubuntu.com/questions/1089753/…
    – poleguy
    Jun 20, 2022 at 14:07
44

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.

4
  • I am having this error on a Mac. Solution isn't applicable to Macs because they have no BIOS. What to do then? Jul 6, 2017 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, 2017 at 5:11
  • 1
    How to go into bios? May 9, 2018 at 9:11
  • @Riddhi, it depends on your computer. Usually hit DEL or F12 or F1 when it says.
    – psusi
    May 9, 2018 at 16:04
18
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

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

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
6

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.

1
  • This worked for me on Ubuntu 18. First had to enable on BIOS and then use chown as there was no permissions
    – HalfMens
    Sep 4, 2020 at 20:23
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.

2
  • 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, 2017 at 0:37
  • 2
    @earthmeLon I fixed it.
    – wjandrea
    Jan 28, 2017 at 2:07

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .