This error is because you have virtualbox and kvm installed. The kernel modules conflict.
The "simple" solution is to use one or the other, but not both. You can, however, use both as long as you are willing to manually (or script) loading / unloading the kernel modules.
To see your modules
#Virtualbox modules
sudo lsmod | grep vbox
#kvm
sudo lsmod| grep kvm
To remove a module
# remove virtualbox
sudo rmmod vboxdrv
sudo rmmod vboxnetflt
#remove kvm
sudo rmmod kvm
sudo rmmod kvm_amd
use insmod
sudo insmod /full/path/to/your/modules
You can find the module with
locate kvm | grep .ko
locate vbox | grep .ko
Use the modules for your current kernel.
Answer from Panther on askubuntu.comThis error is because you have virtualbox and kvm installed. The kernel modules conflict.
The "simple" solution is to use one or the other, but not both. You can, however, use both as long as you are willing to manually (or script) loading / unloading the kernel modules.
To see your modules
#Virtualbox modules
sudo lsmod | grep vbox
#kvm
sudo lsmod| grep kvm
To remove a module
# remove virtualbox
sudo rmmod vboxdrv
sudo rmmod vboxnetflt
#remove kvm
sudo rmmod kvm
sudo rmmod kvm_amd
use insmod
sudo insmod /full/path/to/your/modules
You can find the module with
locate kvm | grep .ko
locate vbox | grep .ko
Use the modules for your current kernel.
This problem has solved by following codes in terminal:
sudo killall VBoxSVC
export VBOX_HWVIRTEX_IGNORE_SVM_IN_USE=true
VirtualBox
Videos
When I launch VirtualBox first off I get a cant enumerate USB device error and then when I try and open any of the Virtual Machines I get the following Error "VirtualBox can't enable the AMD-V extension. Please disable the KVM kernel extension".
Now doing a search on this error I discover that you cannot run Qemu and VirtualBox together. So As I've been mainly using VirtualBox I decided to uninstall qemu and virt-manager and all dependancies.
Unfortunately this hasnt worked and Im still getting the same error. SO I searched "how to disable KVM kernel extension"
I found instruction on how to temporarily disable them and how to permanently remove them.
It said to create a blacklist
sudo nano /etc/modprobe.d/blacklist-kvm.conf
and then add
blacklist kvm
blacklist kvm_amd
Surely there is a way to just remove these modules and wont this mean that VirtualBox also wont work?
In version 6.12 of the Linux kernel, kvm module initialisation was changed — it now takes place as soon as the modules are loaded, and not the first time they are used. This prevents VirtualBox from working, as you discovered. This is documented in the VirtualBox 7.1.4 release notes. Since your system was upgraded from 6.11 to 6.14, that explains the sudden appearance of the symptoms.
To return to the previous situation (where KVM modules can be loaded without preventing VirtualBox from working), you can add kvm.enable_virt_at_load=0 to the kernel boot parameters. If you’re using Grub on a Debian derivative, that’s done by adding the parameter to the GRUB_CMDLINE_LINUX_DEFAULT= line in /etc/default/grub, then running sudo update-grub. After a reboot, this will allow VirtualBox to work, without preventing any other KVM-based tool from working either.
The other option is to disable the KVM modules entirely; this is safe, but will prevent any KVM-based tool from working. See cas’ answer for details.
Create (as root) a file called /etc/modprobe.d/kvm.conf with the following lines:
blacklist kvm
blacklist kvm-amd
Save it and run update-initramfs -u -k all (again, as root). If you use dracut or something else instead of initramfs you'll have to figure out the command to update it yourself (I've never used dracut)... or maybe someone here knows how and will mention it in a comment so I can update my answer.
To remove kvm and kvm-amd from the currently running kernel without needing to reboot, run:
modprobe -r kvm
You may also need to run modprobe -r kvm_amd but I think just kvm alone will be enough. If something is currently using the kvm modules (e.g. libvirt), you'll have to kill that before you'll be able to remove the modules.
Execute this:
$ VBoxManage modifyvm <VirtualMachineName> --nested-hw-virt on
For Windows
In Windows, go to VirtualBox installation folders -> type cmd on the bar (it will pop up cmd in that folder) -> type VBoxManage modifyvm <YourVirtualMachineName> --nested-hw-virt on -> enter.
Now the option should be checked.
Old laptop needs to run a virtual machine (using VirtualBox) with Debian-12.5.0 for a uni project.
Error code is:
"Not in a hypervisor partition HVP= 0 (VERR_NEM_NOT_AVAILABLE) AMD-V is disabled in the BIOS (VERR_SVM_DISABLED)"
However, I am unable to make any changes in the BIOS. I've updated the BIOS and tried a few command lines in cmd with my IT professor but to no avail.
I've just replaced the CMOS battery but the BIOS is still not saving changes and I'm still getting the same error messages.
Laptop specs:
Windows10 Home
AMD A8-7050 Radeon R5
HP 812F mobo
DDR3 4GB RAM
Thank you in advance
On my setup (AMD Ryzen / MSI B450M-A PRO MAX), /proc/cpuinfo listed the svm feature, and lscpu listed AMD-V, even though it was disabled in the BIOS.
The BIOS setting to enable AMD-V was hard to find, as it was located in Overclocking > CPU Features > SVM mode.
Hope this helps people finding this thread.
Step 1
Reboot the computer and open the system's BIOS menu. This can usually be done by pressing the delete key, the F1 key or Alt and F4 keys depending on the system.
Select Restore Defaults or Restore Optimized Defaults, and then select Save & Exit.
Power off the machine and disconnect the power supply.
Step 2
Enabling the virtualization extensions in BIOS
Power on the machine and open the BIOS (as per Step 1).
Open the Processor submenu The processor settings menu may be hidden in the Chipset, Advanced CPU Configuration or Northbridge.
Enable Intel Virtualization Technology (also known as Intel VT) or AMD-V depending on the brand of the processor. The virtualization extensions may be labeled Virtualization Extensions, Vanderpool or various other names depending on the OEM and system BIOS.
Enable Intel VTd or AMD IOMMU, if the options are available.
Save & Exit.
Run
cat /proc/cpuinfo | grep --color 'vmx\|svm'
If you see vmx or svm in red, the virtualization extensions are now enabled. If there is no output your system may not have the virtualization extensions or the correct BIOS setting enabled.