Adding an existing VHD to the Windows 7 boot loader
In my last post I wrote about how to install Windows Server 2008 R2 into a VHD for dual-booting purposes. Well, recently I broke my laptop and had to rebuild my boot loader. Anyways, adding an existing VHD to the Windows 7 boot loader is a doddle.
First, copy your current boot loader:
bcdedit /copy {current} /d "Boot Description"
This will generate a new boot entry and print out the GUID. You’ll need this! Next, you’ll set the VHD path for the OS to use.
bcdedit /set {GUID from last step} osdevice vhd=[DriveLetter:]\PathToVHD\VHD_File
bcdedit /set {GUID from last step} device vhd=[DriveLetter:]\PathToVHD\VHD_File
That’s it! Reboot your PC and your VHDs should be bootable. Remember though, you can only boot Windows 7 or Windows Server 2008 R2 VHDs like this.