Monday, July 7, 2008

Virtualbox: Virtual Machines on your OS

Virtualbox is an open source software for emulating one software on another which I recently discovered. To put it simply it allows you to calculate virtual machines on your system. This means that you can install one OS within another. For example you could have a virtual machine with Windows XP on your system. This is what I did. I did this on a Debian Lenny system and am telling how I did it here.

First ensure that you are updated with the debian lenny repository.
1. apt-get install virtualbox-ose virtualbox-ose-source virtualbox-ose-modules-2.6-486 module-assistant
This will install the necessary software including the 486 image. Install appropriate module as per your need and ensure you are in that kernel after reboot.
2. module-assistant prepare
This prepares your module setup ensuring that your headers package is alright because this is the one against whom all the modules are compiled.
3. module-assistant auto-install virtualbox-ose
This installs the necessary modules.
4. modprobe vboxdrv
This loads the module.
5. Open the virtualbox software and follow the gui for making machines. Put type as XP. Ensure you have allowed CDs mounting. You can add XP installation CD and install it.

The new version allows shared folders also. In virtualbox you can decide the shared folders. These can be accessed by settings in My Network places.
1. go to 'My Computer' in WinXP and click on 'My Network Places'
2.
select 'Choose another network location' and click 'Next' in service providers.
3.
Browse to 'My Network Places' >> 'Entire Network' >> 'VirtualBox Shared Folders'. Here you will find the folder that you shared earlier using 'Devices' menu in VirtualBox VM as '\\VBOXSVR\...' Choose that folder and then click 'OK' to exit. And 'Next' to continue
4, Give a name to it and you are in business!
you may also need to install the
guest extensions for that machine.
This gives the stability of linux underneath and an unstable XP inside. It runs really fast on my system!
Virtualbox is an open source software available for Linux, windows and Mac OS X also. But remember its an an x86 virtualization software package developed by Sun Microsystems. So will work on x86 and amd64 machines only.

2 comments:

Sach1 said...

Thank you so much for putting this post..I was looking for this for long until came up to the right post :)

Gajendra said...

You are most welcome. Glad to be useful.