How do I install the virtualbox-dkms package?
I have tried installing the linux-source package, but I am not sure how Ubuntu handles kernel sources and headers. Any ideas on how to do this from an Ubuntu standpoint?
7 Answers 7
My Virtual Box told me that the kernel drivers were not installed. I ran
sudo apt-get remove virtualbox-dkms
to remove the drivers and then re-installed them
sudo apt-get install virtualbox-dkms
which rebuilt the drivers and I was able to run virtualbox with no problems
apt-get install linux-headers-`uname -r` dpkg-reconfigure virtualbox-dkms
Wonder why “an other way” is mentioned before the “normal” one. However, dpkg-reconfigure seems to be the right option.
To add to this, I found the following sequence worked when I unpgraded to 16.04: sudo apt-get install linux-headers-`uname -r` then sudo dpkg-reconfigure virtualbox-dkms and finally sudo dpkg-reconfigure virtualbox
You need the kernel header as well. Based on your output, sudo apt-get install kernel-headers-3.5.0-17-generic should do it. On the guest VM, either autorun the ISO image or sudo sh ./VBoxLinuxAdditions.run from the shell prompt should work. Appears this is a known problem with the latest 12.10 release.
This is caused by the kernel headers not being available. These headers are not typically required, but help other applications need them to build kernel modules to keep in sync with your distribution and the version you are using.
You can install specific headers, or you can install ‘generic’, or ‘current’:
sudo apt install linux-headers-generic
This will ensure that when you take in new kernels, the headers of those kernels are also installed. When you update your kernel, VirtualBox will be able to update itself with the newest, matching headers. Sometimes these can be found by other names, such as linux-headers-amd64 , in other distributions.
After you have the headers, you can purge/re-install VirtualBox, or have VirtualBox rebuild the modules and complete the setup:
sudo dpkg-reconfigure virtualbox-dkms sudo modprobe vboxdrv
«Failed to start LSB: VirtualBox Linux kernel module» [duplicate]
Ubuntu-server 17.04 x64, Cinammon 3.2.7, Kernel 4.13.3 generic. Attempting to set up VirtualBox, though so far I have been unable to start any virtual machine. Upon installation (apt install virtualbox), I get the following lines near the end of the installation process:
● virtualbox.service - LSB: VirtualBox Linux kernel module Loaded: loaded (/etc/init.d/virtualbox; generated; vendor preset: enabled) Active: failed (Result: exit-code) since Thu 2017-09-21 19:57:07 +04; 18ms ago Docs: man:systemd-sysv-generator(8) Process: 463 ExecStart=/etc/init.d/virtualbox start (code=exited, status=1/FAILURE) CPU: 28ms Sep 21 19:57:06 Hiigaran systemd[1]: Starting LSB: VirtualBox Linux kernel module. Sep 21 19:57:06 Hiigaran virtualbox[463]: * Loading VirtualBox kernel modules. Sep 21 19:57:07 Hiigaran virtualbox[463]: * No suitable module for running kernel found Sep 21 19:57:07 Hiigaran virtualbox[463]: . fail! Sep 21 19:57:07 Hiigaran systemd[1]: virtualbox.service: Control process exited, code=exited status=1 Sep 21 19:57:07 Hiigaran systemd[1]: Failed to start LSB: VirtualBox Linux kernel module. Sep 21 19:57:07 Hiigaran systemd[1]: virtualbox.service: Unit entered failed state. Sep 21 19:57:07 Hiigaran systemd[1]: virtualbox.service: Failed with result 'exit-code'.
Tried following the top answer in this question, by removing virtualbox-dkms and installing it again. This resulted in the same lines as above. Attempting to start a virtual macine, I get an error giving the following details:
Kernel driver not installed (rc=-1908) The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a permission problem with /dev/vboxdrv. Please reinstall virtualbox-dkms package and load the kernel module by executing 'modprobe vboxdrv' as root. where: suplibOsInit what: 3 VERR_VM_DRIVER_NOT_INSTALLED (-1908) - The support driver is not installed. On linux, open returned ENOENT.
modprobe: FATAL: Module vboxdrv not found in directory /lib/modules/4.13.3-041303-generic
Failed to start LSB: Virtualbox Linux kernel module [closed]
This question is specific to an end of life Ubuntu release. These are no longer supported and are therefore off-topic here. To upgrade, see: How to install software or upgrade from old unsupported release?
When I try to boot Ubuntu my system shows this.. i have two operating systems windows 10-ubuntu 15.10. when i try to boot ubuntu it appears the ubuntu logo and after that this error..so i cannot log in or open up my terminal.. How can I deal with this problem?
open a terminal with ctrl + alt + t then type in sudo systemctl status virtualbox.service and after copy from terminal by using mouse, drag over the text in terminal and right click to copy
Please put more detail into your question so you can get better help. Include the computer specs, OS version etc
1 Answer 1
Turn off secure boot in your BIOS. That should fix it.
To enter your BIOS, turn on your computer, and watch the BIOS flash screen and it’ll usually tell you what key to touch to enter the BIOS (usually a function key). Once in the BIOS settings, depending on your BIOS, you might see a security section or tab. Find the secure boot option and turn it off, save your changes, and reboot the computer.
To perform a file system check.
- boot to the GRUB menu (where you select which OS to start)
- choose Advanced Options
- choose Recovery mode
- choose Root access
- at the # prompt, type sudo fsck -f /
- you can ignore errors about the time/date/superblock
- repeat the fsck command if there were other errors
- type reboot
- boot to the GRUB menu (where you select which OS to start)
- choose Advanced Options
- choose Recovery mode
- choose Root access
- at the # prompt, type:
- sudo mount -o rw,remount /
- sudo dpkg -P virtualbox-qt
- sudo dpkg -P virtualbox
- reboot
To try and fix failed updates.
- boot to the GRUB menu (where you select which OS to start)
- choose Advanced Options
- choose Recovery mode
- choose Root access
- at the # prompt, type:
- sudo mount -o rw,remount /
- sudo dpkg —configure -a
- sudo apt-get install -f
- reboot
After many failed attempts to fix the problems, you’re going to have to reinstall Ubuntu. I don’t think that the virtualbox install caused this problem. There must have been something wrong before, even if you didn’t know it. I’d always recommend that you have good Windows and Ubuntu backups, just in case anything goes wrong. You’ll need a Ubuntu 15.10 DVD/USB, choose reinstall so that it reinstalls into the same place as is currently used, but make sure to uncheck format partition so it’ll keep your /home directory.