1

I am unable to get Virtual Box to load since upgrading to Ubuntu 12.10. It tells me to rebuild the kernel modules by running /etc/init.d/vboxdrv setup. When I do in terminal the system cannot find the linux-headers-3.2.0-32-generic. I checked /usr/src and the only headers there are for versions 3.5.0-17 and 3.5.0-18.

Can anyone please tell me how to recreate the headers that the system is looking for?

user.dz
  • 48,105

3 Answers3

2

Well, due to kernel version I guess you have Ubuntu 12.10 (12.11 is not a version of Ubuntu, please edit your question and correct it).

Then you said that virtualbox not work due to missing headers of 3.2.0-32 kernel. This kernel is from 12.04 Ubuntu version . Ubuntu 12.10 uses 3.5.0-17 (3.5 series). So the only thing I can guess is that you've upgraded from 12.04 to 12.10 and the old kernel remained to your system.

The easy solution here is to remove the old kernel 3.2.0-32.

See here on how to remove the old kernel

Then run again sudo /etc/init.d/vboxdrv setup and should be fine.

NickTux
  • 17,539
2

You have to install linux headers, remove virtualbox-dkms and install virtualbox-dkms. The step by step instructions are given in the following link, http://xchamitha.blogspot.co.uk/2012/11/fixing-virtualbox-on-ubuntu-1210.html

1

I followed the advice of @NikTh but that made my system unable to boot. It appears that the Grub boot loader did not completely upgrade when I upgraded Ubuntu to Version 12.10. The package was extracted but not installed. I was able to determine this fact after making a command line boot to kernel 3.5.0-18. I then rebooted from my original installation CD of version 9.04 and from the menu chose "Recover a broken system". Then at the rescue-mode chooser I selected "Reinstall GRUB boot loader". This solved my problem by correcting the errors in the boot loader and therefore providing pointers to the current kernel for vbox to function again.