I received a tweet from Jeffery Hicks that many of you want to know how I did the boot from VHD with Windows (Server/Client 8. Here we go!

image


INTRODUCTION

The four steps are:

  1. Prepare VHD
  2. Locate install.wim image
  3. Apply Windows *.wim image to VHD
  4. Configure VHD for native boot

From an administrator command prompt in Windows 7 or Windows Server 2008 R2 (SP1):

Create VHD
  • > diskpart
  • > create vdisk file=”[drive]:\vhd\winsrv8devprev.vhd” maximum=40000 type=FIXED
  • > select vdisk file=”[drive]:\vhd\winsrv8devprev.vhd”
  • > attach vdisk
  • > create partition primary
  • > assign letter=W   #can be any free drive letter; cancel popup to format this disk
  • > format quick fs=ntfs label=WINSRV8DEVPREV
  • > exit
LOCATE INSTALL.WIM IMAGE
  • Check that install.wim and the powershell script are in the [drive]:\vhd directory

 

APPLY WIM IMAGE TO VHD
  • > cd [drive]:\vhd
  • > Powershell
  • PS> set-ExecutionPolicy Unrestricted
  • PS> .\Install-WindowsImage.ps1 –WIM [drive]:\vhd\install.wim
  • PS> [R}un once

You know see there is one or more images:

image

  • PS> .\Install-WindowsImage.ps1 –WIM [drive]:\vhd\install.wim –Apply –Index 1 –Destination W:
  • PS> [R}un once

This may take up to 15 minutes. With a fast SDD this is much shorter

image

CONFIGURE VHD FOR NATIVE BOOT

  • > bcdboot w:\windows

You can now check the boot entries with

  • > bcdedit /v

If you want this installation of Windows 8 to also support Hyper-V, add the following entry to your boot configuration

  • Find the GUID of the Windows 8 boot part which is between { }
  • Make a copy of your boot file with
  • > bcdedit /export “\temp\bcdbackup”
  • Add hypervisor entry
  • > bcdedit /set {ee73a92b-c385-11e0-a663-be9bd6f43bf9} hypervisorlaunchtype auto

After you reboot, the sysprepped Windows 8 Developers Preview will start and you can configure your Windows 8 server or client.

Don’t panic if you don’t see a boot choice when you start your computer. The boot choice is moved to the Windows 8 Boot Loader Screen which looks very pretty.

Well, good luck and let me know if it has been successful. If you find any mistakes, also let me know!

A few retweets might help Glimlach