Getting you started => How to's => Topic started by: M0E-lnx on August 05, 2010, 01:10:53 pm

Title: How to boot an existing partition with Vectorlinux on VirtualBox
Post by: M0E-lnx on August 05, 2010, 01:10:53 pm
This howto explains how to boot a VL partition in Virtualbox.

Consider a scenario where you have several linux distros installed, but you're only able to use one of them at a time, in this case, this howto will allow you to setup a virtual machine via Virtualbox and you'll be able to boot one of your other installations right from inside your current install.

Let's get started.

First off you'll need to create a .vmdk disk for virtualbox to use. The default .vdi format will not work, first we need to locate your VBoxManage binary.
Code: [Select]
find / -name VBoxManage
Once you find the location of the binary, cd to that dir. (This may not be necessary if VBoxManage is in your $PATH)

Creating the image.
Let's assume that your target OS is installed in /dev/sdb1, so execute the following command replacing /dev/sdb1 with whatever your partition is.

Code: [Select]
VBoxManage internalcommands createrawvmdk -filename /path/to/where/you/want/your/partition.vmdk -rawdisk /dev/sdb1 -register
Some of this is obvious like -filename followed by the absolute path to your target vmdk, and -rawdisk followed by the actual partition address that you want to boot with VBox. The -register argument at the end tells it to register the new drive in the virtualbox media manager. If you do not specify this argument, you'd have to look for it yourself, and add it to the list, no biggie'

So, if everything went fine, It should answer with something like "vmdk created ...."
If you do not, ask in a thread somewhere and reference this howto so I can fix it later.

If everything went fine, then it's time to fire up VirtualBox.

Create a new virtual machine
pick your settings, RAM, CPU, and all needed stuff
Make sure that for the Disk to use, you pick your newly created .vmdk file.

That should be it.

Now, you can boot your partition with virtualbox.
If there is nothing installed in the partition, you may begin installing VectorLinux, or any OS for that matter on this partition.