« Ubuntu Linux 11.04 and Microsoft VPN quirks | VLC for Android download apk package updated » |
I usually set up my workstations with both Windows and Linux. However, I like to boot into the Windows partition from Linux without rebooting into Windows natively. This can be achieved by using any of the virtualisation softwares like VMWare or VirtualBox and booting into the virtual disk setup as a raw disk drive and pointed to a real dev as oppose to a virtual image.
One of the dangers of this setup is the potential of screwing up your mounted Linux partition if you accidentally boot into the same Linux partition. Hence, to prevent such tragedies from occurring, I usually setup my virtualisation software to boot off a GRUB floppy image configured to boot straight into my Windows partition bypassing my main GRUB which allows me to choose booting Linux or Windows.
There are many instructions on building your own GRUB boot floppy disks such as http://wiki.osdev.org/Disk_Images#Images_with_preinstalled_GRUB
Instead, I’ve uploaded my pre-built GRUB boot disks which are running a legacy version of Grub 0.97.
vmbootdisk0.img - automatically boots Windows in first partition of primary drive.
vmbootdisk1.img - automatically boots Windows in second partition of primary drive.
If you have windows on another drive other than the first or second partition above, simply change it by
sudo mount -o loop vmbootdisk.img /mnt
This mounts the image on a loop device and allows us to edit the contents of the image.
Once mounted, edit /mnt/boot/grub/menu.lst (Ensure not to edit your live system’s menu.lst) and change the root device.
root (hd0,0)
Here, you can specify which partition and drive to boot Windows. For more info see the official grub manual