How To Fix Virtualbox After Upgrading Ubuntu
Yesterday I decided to upgrade my installation of Ubuntu 8.04.1 to 8.10 Release Candidate. The upgrade went over pretty smoothly, save for a few minor bugs that were easy to fix (bugs are to be expected when you’re using “beta” software). But the biggest issue I had after upgrading was with trying to run Virtualbox. The first error message I got when I attempted to start up my XP machine in Virtualbox was this:
The VirtualBox kernel driver is not accessible to the current user. Make sure that the user has write permissions for /dev/vboxdrv by adding them to the vboxusers groups. You willneed to logout for the change to take effect..
VBox status code: -1909 (VERR_VM_DRIVER_NOT_ACCESSIBLE).
This threw me off because, for one, I am already a member of the vboxusers group. And attempting to recompile the kernel headers using the sudo /etc/init.d/vboxdrv setup terminal command also did not work. So I had to do a little digging around and finally found the solution, and it is EASY!
The Magic Trick
Let’s keep this short and sweet, okay? We have four things to do:
- Copy and Paste an entry to our Software Sources list
- Copy and Paste a command into a terminal window
- Copy and Paste a line into our fstab file
- Run Update Manager
Click on System>Administration>Software Sources. You will be asked to enter you administrator password. Once open, click on the “Third-Party Software” tab. You will likely see something that looks like this:

You can just ignore all of those entries that are unchecked. What we want to do is add one to this list. Click the Add+ button at the bottom left and then paste in the following text in the box that appears:
- deb http://download.virtualbox.org/virtualbox/debian hardy non-free
I know some of you out there are thinking, “Hardy? I thought we’re running Intrepid Ibex now…” Don’t worry, it will work. Now that you’ve added the above text, click the Add Source button. It will add a new entry to the window. You can click the close button now. The following message will then appear:

Click Reload.
Now, open a Terminal window by clicking Applications>Accessories>Terminal.
In here, copy and paste in the following text by using the Edit>Paste menu option in the Terminal window.
-
wget -q http://download.virtualbox.org/virtualbox/debian/sun_vbox.asc -O- | sudo apt-key add -
Be sure to include all the text above (from the wget to the minus-sign at the end) when copying. Paste the text into Terminal and press enter (if necessary). It may also ask you for your administrator password again.
We’re already half way finished. Now we need to add a line of text to our fstab file. We are doing this to reestablish Virtualbox’s access to your USB ports. To edit the file, paste this into the terminal window you should still have open (open another one if you closed the first one).
- sudo gedit /etc/fstab
This will open a text editor. Paste in the following text at the very bottom of the file:
- none /proc/bus/usb usbfs devgid=46,devmode=666 0 0
You don’t need to make any other changes to the file, though if you see another line at the bottom of the fstab that looks very similar to the one you just pasted it, comment it out by inserting a couple of pound-symbols ## in front of that line, like this:
- ##none /proc/bus/usb usbfs devgid=125,devmode=664 0 0
I suggest commenting out, as opposed to deleting it completely, so that if there is a problem after, you can just reverse the edit you made by removing the pound signs later. You don’t have to do this if you don’t want to though. I did it just to be tidy. For this edit to take effect, you will need to restart the computer after saving the file.
Finally, once you are booted up and running again, run System>Administration>Update Manager. Check for updates, apply all that are available, and you should be good to go!
If this fails, try downloading the latest copy of Virtualbox from http://www.virtualbox.org/wiki/Linux_Downloads and reinstall it (although I did not have to do this as Update Manager took care of all downloading and upgrading automatically after following the above steps).
A new feature has been implimented in 8.10 that will automatically update the kernel headers whenever there are future Linux Kernel updates, so you should’t have to worry about recompiling them in the future. However, it is possible that come Ubuntu 9.04, you may have to repeat the above steps (or something close to them) in order to fix Virtualbox again. The alternative to this is to not upgrade Ubuntu to the latest distrobution, which is perfectly fine because 8.04 has Long Term Support (LTS) and will continue to recieve normal updates until April, 2011.
November 1st, 2008 at 9:43 am
Thanks for putting this together. Unfortunately, I’m left with the same error that I received previously:
VERR_VM_DRIVER_NOT_INSTALLED (rc=-1908)
The VirtualBox Linux kernel driver (vboxdrv) is either not loaded or there is a permission problem with /dev/vboxdrv. Re-setup the kernel module by executing
‘/etc/init.d/vboxdrv setup’
as root. Users of Ubuntu or Fedora should install the DKMS package at first. This package keeps track of Linux kernel changes and recompiles the vboxdrv kernel module if necessary.
I’ve performed your suggestions twice, and rebooted in-between, but no luck alas. Any ideas, Dave? Any suggestions gratefully received. Thank you. Ian
November 1st, 2008 at 2:09 pm
Follow-up to my previous post: I’ve removed VB and then reinstalled from the site and everything seems to be working. Once again, many thanks.
November 14th, 2008 at 3:35 am
sudo /etc/init.d/vboxdrv setup worked great for me after kubuntu 8.10 update.
Thanks for the help
November 15th, 2008 at 12:08 pm
Hey Dave, just to tell you you are the best!
It worked “out of the box” for me, after I had spent hours trying to understand what could have caused the issue.
100 points +!
Thanks, Titus.
November 28th, 2008 at 5:56 am
Thank you so much!
The solution for me was also:
sudo /etc/init.d/vboxdrv setup
Regards,
Macufendo.