Home » Questions » Computers [ Ask a new question ]

How to import existing Linux partition into VirtualBox as guest?

How to import existing Linux partition into VirtualBox as guest?

I recently upgraded to Windows 7 (from Windows Vista). I assumed, unwisely, that because it was an upgrade it wouldn't need to screw around with the MBR. However, it apparently did, with the result that my Linux partition is now invisible until such time as I reinstall LILO.

Asked by: Guest | Views: 346
Total answers/comments: 1
bert [Entry]

"This is documented in the VirtualBox help files (""Advanced topics"", then ""Using a raw host hard disk from a guest""). Since it's hard to link within the help file, I'll give you a brief description of what you need to do.

First, run VBoxManage internalcommands. The actual internal command you need is createrawvmdk, but the syntax is described in the help text generated by that command, so I won't repeat it here.

Once you've created the raw .vmdk, you need to go to the Virtual Media Manager inside VirtualBox and add it.

You will then probably need to boot off your Debian CD/DVD in rescue mode, so you can adjust the /etc/fstab and /boot/grub/menu.lst (or /boot/grub/grub.cfg) appropriately.

Good luck!"