VirtualBox vboxdrv problem on Ubuntu

Problem Statement:


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 the kernel module by executing

/etc/init.d/vboxdrv setup

as root. If it is available in your distribution, you should install the DKMS package first. This package keeps track of Linux kernel changes and recompiles the vboxdrv kernel module if necessary.


Failed to open a session for the virtual machine “Windows XP”.

The virtual machine ‘Windows XP’ has terminated unexpectedly during startup with exit code 1.

(Running a virtual machine on VirtualBox the two dialogues would say that)

The cause — as the VirtualBox page states it:

Ubuntu/Debian users might want to install the dkms package to ensure that the VirtualBox host kernel modules (vboxdrv, vboxnetflt and vboxnetadp) are properly updated if the linux kernel version changes during the next apt-get upgrade.

The Fix:

The dkms package can be installed through the Synaptic Package manager or through the following command:

sudo apt-get install dkms

Running `virtualbox` in the terminal says almost the same thing…

$ virtualbox
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
available for the current kernel (3.5.0-18-generic) or it failed to
load. Please recompile the kernel module and install it by

sudo /etc/init.d/vboxdrv setup

You will not be able to start VMs until this problem is fixed.
# You have heard the man!
$ sudo /etc/init.d/vboxdrv setup
* Stopping VirtualBox kernel modules [ OK ]
* Uninstalling old VirtualBox DKMS kernel modules [ OK ]
* Trying to register the VirtualBox kernel modules using DKMS
Error! Your kernel headers for kernel 3.5.0-18-generic cannot be found.
Please install the linux-headers-3.5.0-18-generic package,
or use the --kernelsourcedir option to tell DKMS where it's located

* Failed, trying without DKMS
* Recompiling VirtualBox kernel modules
* Look at /var/log/vbox-install.log to find out what went wrong
# Downloading the Linux Headers now
# sudo apt-get install linux-headers-3.5.0-18-generic
$ sudo apt-get install linux-headers-`uname -r`
# Running it again
$ sudo /etc/init.d/vboxdrv setup
* Stopping VirtualBox kernel modules                          [ OK ]
* Uninstalling old VirtualBox DKMS kernel modules             [ OK ]
* Trying to register the VirtualBox kernel modules using DKMS [ OK ]
* Starting VirtualBox kernel modules                          [ OK ]

All good!


Missing “Safely Remove” in Ubuntu 12.10

Strange isn’t it?

There was a time when all you had to do was “Safely Remove” and see the progress bar dance for a few seconds — and you were golden.

Those were the days! Anyway it turns out unmount/eject/safely remove are all meant to do different things.

Yes we are talking about our near and dear external hard-disks. (think: WD, Segate, FreeAgent Blah Blah)


Now with Ubuntu 12.10, only “unmount” is available on “Nautilus”! Even “Thunar” is no good.

(*these are lets say pretty awesome “Windows Explorer” in the world of Linux)

Well people have even reported it [bug]. Please feel free to mark it “The Bug affects You”.



What do you mean “why”? Its a BUG. The beauty of opensource is that someone will fix it. Sit back and relax. Its not urgent anyway.

So why this post?

Well who would not want to make sure that their Hard Drive is doing well and not in an inconsistent state — unable to do the most important thing that they are supposed to do — SAVE DATA! You wouldn’t want a lossy storage. Anyway, the point is — to make sure that all the data was written to the harddisk before you unplugged it — you’d need to UNMOUNT it. You always should. And if there are more than one partitions on the Hard Drive then you need to unmount each and everyone separately (which was earlier taken care by “SAFELY REMOVE”).


Still the Harddisk keeps spinning. You can feel it. You can even hear it. And the LED would just keep glowing.

So until they fixed it, we have a work around.

Spin down the harddisk

I found answers to my queries here:

I created a quick shell script

echo "Unmounting disks..."
udisks --unmount /dev/sdb1
udisks --unmount /dev/sdb2

#udisks --unmount /dev/sdb3
#depending on the number of partitions you have on your drive edit above
#please make sure all the partitions are unmounted before you detach

echo "Spinning down!"
udisks --detach /dev/sdb
echo "All done!"

Execute it …

$ chmod u+x
$ ./
Unmounting disks...
Spinning down!
All done!

Or even better — Save it on Desktop

Just double click; “Run” and you are almost “GOLDEN” again!


Happy Hackin’