Install virtualbox 4.2.6 on ubuntu 12.10 precise

0 Flares Filament.io 0 Flares ×

Virtualbox

Virtualbox is the most popular virtualisation solution for x86 and AMD64/Intel64 platforms. Its featureful yet very easy to use. If you are virtualising then its recommended to have the latest version installed so that all recent operating systems will have best compatibility in the virtual environment.

The software repository of Ubuntu 12.10 contains an older version of virtualbox (4.1.18). To install the latest version of virtualbox on ubuntu precise do the following

Add the virtualbox repository to the apt source file

$ gksudo gedit /etc/apt/sources.list

add the following line to the end of the file

deb http://download.virtualbox.org/virtualbox/debian precise contrib

Install the PGP key using the following command

$ wget -q http://download.virtualbox.org/virtualbox/debian/oracle_vbox.asc -O- | sudo apt-key add -

The wget command gets the key which is fed into the apt-key command.

Update the package list

$ sudo apt-get update

Install VirtualBox 4.2.6

$ sudo apt-get install virtualbox-4.2

If you do not want to follow the above steps then download the deb file directly from

https://www.virtualbox.org/wiki/Linux_Downloads

and install it right away.

Compile the VirtualBox Kernel modules

After the virtualbox package is installed, the kernel modules have to be compiled. Without it virtualbox wont run.

First install the linux headers.

$ sudo apt-get install linux-headers-`uname -r`

Now compile virtualbox kernel modules

$ 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 ] 
$

If all the steps show OK, then the compilation succeeded and now virtualbox is ready to use. If any error occurs then the "/var/log/vbox-install.log" file will contain details about what went wrong.







Last Updated On : 29th May 2013

Subscribe to get updates delivered to your inbox

About Silver Moon

Php developer, blogger and Linux enthusiast. He can be reached at m00n.silv3r@gmail.com. Or find him on

0 Flares Twitter 0 Facebook 0 Google+ 0 LinkedIn 0 StumbleUpon 0 Filament.io 0 Flares ×