VM中,无法使用X86_64模拟器

来源:互联网 发布:关键词大数据 编辑:程序博客网 时间:2024/06/09 15:41

在ubuntu虚拟机中,使用X86_64架构的Android模拟器,有时候会出现如下错误:

emulator: ERROR: x86_64 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).

The err shows that the VM doesn’t have the KVM

For the problem,The solution:

1,Check that your CPU supports hardware virtualization

To run KVM, you need a processor that supports hardware virtualization. Intel and AMD both have developed extensions for their processors,deemed respectively Intel VT-x (code name Vanderpool) and AMD-V (code name Pacifica). To see if your processor supports one of these, you can review the output from this command:egrep -c '(vmx|svm)' /proc/cpuinfoIf 0 it means that your CPU doesn't support hardware virtualization.If 1 or more it does - but you still need to make sure that virtualization is enabled in the BIOS.So, firstly close your VM, go to the VM Setting panelOpen Virtual machine setting.Go to the processor.Check the virtualize Intel VT-x/EPT or AMD-RVI option.Click ok and run the Virtual machine, it should work fine with you.then reboot your VM

2,Install KVM for VM

sudo apt-get install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utilssudo adduser `id -un` libvirtdsudo adduser `id -un` kvmCheck success or notsudo kvm-ok
阅读全文
0 0