Virtualbox error Kernel driver not installed (rc=-1908)

Hello, virtualbox does not work when secureboot is enabled.

Kernel driver not installed (rc=-1908)

The VirtualBox Linux kernel driver is either not loaded or not set up correctly. Please try setting it up again by executing

‘/sbin/vboxconfig’

as root.

If your system has EFI Secure Boot enabled you may also need to sign the kernel modules (vboxdrv, vboxnetflt, vboxnetadp, vboxpci) before you can load them. Please see your Linux system’s documentation for more information.

where: suplibOsInit what: 3 VERR_VM_DRIVER_NOT_INSTALLED (-1908) - The support driver is not installed. On linux, open returned ENOENT.

How to fix it? I don’t want to disable secureboot.

See:

1 Like

Please explain in detail how to make it work; I have little experience.

I followed these instructions up to step 12 and registered the key, but VirtualBox isn’t working.
Issuer: CN=DKMS module signing key
Subject: CN=DKMS module signing key

I had no problems with previous versions of kicksecure. I also registered the key, and VirtualBox worked with secureboot enabled.

Install mokutil package(s) following these instructions.

  1. Platform specific notice.

Kicksecure: No special notice.
Kicksecure-Qubes: In Template.

  1. Update the package lists and upgrade the system.

sudo apt update && sudo apt full-upgrade

  1. Install the mokutil package(s).

Using the apt command line, the --no-install-recommends option is optional in most cases.

sudo apt install --no-install-recommends mokutil

4 Platform specific notice.

Kicksecure: No special notice.
Kicksecure-Qubes: Shut down Template and restart App Qubes based on it as per Qubes Template Modification.

5 Done.

The procedure of installing package(s) mokutil is complete.

  1. Check if Secure Boot is enabled:

sudo mokutil --sb-state

Expected output:

SecureBoot enabled

If Secure Boot is disabled:
If you wish to enable it, see Enable Secure Boot.
If you do not wish to enable it, no further steps from this wiki chapter need to be applied.
If Secure Boot is enabled:
Proceed with the steps below.

  1. Import the DKMS MOK key.

sudo mokutil --import /var/lib/dkms/mok.pub

  1. Password entry.

You’ll be prompted to create a password. Enter it twice.

  1. Reboot the computer.

sudo reboot

Did you see the “Shim UEFI key management” blue screen after rebooting? If not, that’s why things aren’t working and we should debug that.

1 Like

I got a blue screen. I followed the instructions ( Secure Boot ) up to step 12. I did the same thing on older versions of Kicksecure and it worked. The key is added correctly, but VirtualBox doesn’t work. I installed it using virtualbox-installer-cli. I want to reinstall VirtualBox, but I can’t uninstall it; the standard commands don’t work. What’s the command to uninstall VirtualBox?

I think the step that’s missing is that the instructions aren’t telling you to reinstall packages that ship DKMS modules. You might want to try sudo apt reinstall virtualbox-7.2 before giving up. That might get things working.

If you just want to uninstall VirtualBox, sudo apt purge virtualbox-7.2 should work.

1 Like

It looks like the problem is the latest update, I reinstalled the system again and did everything new, but nothing helped. I would be grateful if someone tries to run any operating system in VirtualBox in the latest version of KickSecure with secureboot enabled.

1 Like

VirtualBox just not working with Secure Boot enabled is a big problem, so I’ll put this on my todo list and hopefully find a solution soon.

Edit: This turns out to be a VirtualBox limitation; VBox upstream doesn’t use DKMS, whereas the VirtualBox Debian packages that were available to us in Bookworm did. Debian also doesn’t have the tool VirtualBox tries to use to automatically sign its kernel modules. Thus fixing this will require either Debian or VirtualBox to do something different. Filed a feature request:

Edit 2: I’ve found a workaround! In the sysmaint session, run:

sudo mkdir -p /var/lib/shim-signed/mok
sudo ln -s /var/lib/dkms/mok.key /var/lib/shim-signed/mok/MOK.priv
sudo ln -s /var/lib/dkms/mok.pub /var/lib/shim-signed/mok/MOK.der
sudo apt reinstall virtualbox-7.2

This makes it so that VirtualBox can find the signing keys the wiki directs you to enroll. It then signs its kernel modules with them, and things work. I was able to successfully get VirtualBox working on Kicksecure 18 with Secure Boot enabled by doing this.

1 Like