Dummy guide to install Win 8 on VHD for Boot to VHD

 

Summarized from:

You'll need:

 

Set up boot to VHD!

  1. Create a VHD

clip_image001

clip_image002

Note: I make this a dynamic disk, although I allocated up to 60GB, it only uses what it needs which was about 10 GB.

 

clip_image003

clip_image004

clip_image005

clip_image006

clip_image007

clip_image008

clip_image009

Created, and attached the VHD to Y:

 

Load the ISO into a virtual CD drive, mine is G:

I use virtualclonedrive to load ISO - this is a free utility.

clip_image001[5]

 

Next install the windows image into the VHD

Easiest way that worked for me is this wonderful powershell script.

 

clip_image001[7]

Remember to unblock this script

 

If you see:

File C:\Install-WindowsImage.ps1 cannot be loaded because the execution of scripts is disabled on this system. Please see "get-help about_signing" for more details.

You will need to allow remote script

PS C:\>set-executionpolicy remotesigned

 

PS C:\> .\Install-WindowsImage.ps1 -WIM G:\sources\install.wim

Index   Image Name

[1]     Windows Consumer Preview

Done.

PS C:\> .\Install-WindowsImage.ps1 -WIM G:\sources\install.wim -Apply -Index 1 -Destination Y:

PS C:\> .\Install-WindowsImage.ps1 -WIM G:\sources\install.wim -Apply -Index 1 -Destination Y:
Applying "Windows 8 Consumer Preview" to Y:...
WARNING: This may take up to 15 minutes...

Elapsed Time: 00:08:40.4870618

PS C:\>

 

Lastly, make the VM a boot record.

 

PS C:\> bcdboot Y:\Windows\
Boot files successfully created.

 

You can check it with bcdedit

PS C:\>bcdedit

Windows Boot Loader
-------------------
identifier              {default}
device                  partition=Y:
path                    \Windows\system32\winload.exe
description             Windows 8 Consumer Preview
locale                  en-us
inherit                 {bootloadersettings}
custom:17000077         352321653
osdevice                partition=Y:
systemroot              \Windows
resumeobject            {1abc7489-8e4b-11e0-877a-af036ca44d2f}
nx                      OptIn
custom:250000c2         1
detecthal               Yes

Windows Boot Loader
-------------------
identifier              {current}
device                  partition=C:
path                    \Windows\system32\winload.exe
description             Windows 7
locale                  en-US
inherit                 {bootloadersettings}
recoverysequence        {1abc7482-8e4b-11e0-877a-af036ca44d2f}
recoveryenabled         Yes
osdevice                partition=C:
systemroot              \Windows
resumeobject            {1abc7480-8e4b-11e0-877a-af036ca44d2f}
nx                      OptIn

 

Restart and you are off to go

 

Your PC will boot into Windows 8, which has a new happy looking boot loader.  If you feel the 30 second delay is too long, you can change the delay to 5 seconds from the boot loader options.