I have a Win7 x64 & Ubuntu 11.10 x64 dual boot setup on a single HDD.
I wanted to run the native Ubuntu as a guest OS inside VirtualBox running on Win7 host.
I used the following command to list the partitions:
C:\ >vboxmanage internalcommands listpartitions -rawdisk \\.\physicaldrive0 Number Type StartCHS EndCHS Size (MiB) Start (Sect) 1 0x07 0 /32 /33 153 /27 /2 1200 2048 2 0x07 153 /27 /3 1023/254/63 363337 2459648 5 0x82 1023/254/63 1023/254/63 9537 746575872 6 0x83 1023/254/63 1023/254/63 46430 766107783 7 0x83 1023/254/63 1023/254/63 46431 861200384 4 0x07 1023/254/63 1023/254/63 10000 956291072
Then I created the vmdk file as follows (specifying the ubuntu partitions 5,6 & 7):
C:> vboxmanage internalcommands createrawvmdk -filename "C:\ubuntu_01.vmdk" -rawdisk \.\physicaldrive0 -partitions 5,6,7
The vmdk file was created successfully, but when I created a VM and specified this virtual drive, the VM wont start, theres just a blank black screen with a white cursor at the top left corner. It doesnot even show up the Grub boot menu.
Then I created another vmdk file without specifying the partitions.
C:> vboxmanage internalcommands createrawvmdk -filename "C:\ubuntu_02.vmdk" -rawdisk \.\physicaldrive0
This time the VM starts and ubuntu boots successfully from inside the VM (the grub 2 boot menu is presented and on selecting Ubuntu, it boots successfully).
How can I use only the specific native ubuntu partitions for the guest ubuntu OS ? Please help.
Host: Win 7 x64
Guest: Ubuntu 11.10 x64
Vbox version: 4.1.6 r74713 with latest guest additions installed.