Windows 7 Boot to VHD

Written on April 4, 2011

For my own reference, some useful resources about boot to VHD:

Following instructions from


create vdisk file=C:\VHD\test.vhd maximum=25000 type=expandable      select vdisk file=C:\VHD\test.vhd      attach vdisk      create partition primary      assign letter=v      format quick FS=NTFS label=VHD exit


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

Index   Image Name [1]     Windows 7 Home Basic [2]     Windows 7 Home Premium [3]     Windows 7 Professional [4]     Windows 7 Ultimate


PS C:\VHDs> .\Install-WindowsImage.ps1 -WIM D:\sources\install.wim -Apply -Index 4 -Destination v: Applying “Windows 7 Ultimate” to v:… WARNING: This may take up to 15 minutes…

V:\Windows\System32\bcdboot V:\Windows

bcdedit -v

bcdedit /set {GUID} description=”Windows 7 VHD”

Useful utility BCDEdit -

Categories: PowerShell, Windows 7