I was using VirtualBox (installed from Ubuntu repositories) on the day right before I installed the most recent upgrade for Ubuntu 22.04.2 LTS which installed Linux kernel 6.1.0-1015, previous kernel was 5.15.0-76. Since then I can not start VirtualBox. What can I do? It shows this error:
Kernel driver not installed (rc=-1908)
The VirtualBox Linux kernel driver is either not loaded or not set up
correctly. Please reinstall virtualbox-dkms package and load the
kernel module by executing
'modprobe vboxdrv'
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.
The recommended solution fails:
When trying to reinstall virtualbox-dkms, I can see the problem here:
Loading new virtualbox-6.1.38 DKMS files...
Building for 6.1.0-1015-oem
Module build for kernel 6.1.0-1015-oem was skipped since the
kernel headers for this kernel does not seem to be installed.
Jul 03 20:12:15 Abook systemd[1]: Starting LSB: VirtualBox Linux kernel module...
Jul 03 20:12:15 Abook virtualbox[11380]: * Loading VirtualBox kernel modules...
Jul 03 20:12:15 Abook virtualbox[11380]: * No suitable module for running kernel found