Let's list the steps
- Create a VHD from Disk++Management
- Or create a VHD from Command line using diskpart command
- Attach the VHD if you already have an existing VHD using Disk Management
- Or attach VHD using Command line
- Copy a BCD entry and edit it according to the new value
- Create a VHD from Disk Managment
We can create the VHD from the Disk Management from computer++management, see the following link http://www.sevenforums.com/tutorials/566-virtual-hard-disk-create-attach-vhd.html
- Or create VHD from Command line using diskpart command
1
2
create vdisk file=\"D:pathToVhd.vhd\"
type=expandable maximum=maxsizeInMegabyte
For more information see the following link Windows 7 - VHD Boot - Setup Guideline
- Attach the VHD if you already have an existing VHD using Disk++Management
You can see the first link
- Or attach VHD using Command line
1
2
3
4
Iskpart select vdisk
file=c:windows7.vhd attach vdisk list volume select volume
\<volume_number_of_attached_VHD\> assign letter=v exit
- Copy a BCD entry and edit it according to the new value
First we will see the existing entries by command bcdedit, this will list all existing entries, then we will select the++entry++for the same windows for example I will++select++the++entry++of windows 7 and copy it and then change it's value to the new value,++remember++that we used the GUID to do this
1
2
3
4
bcdedit /copy {originalguid} /d \"New
Windows 7 Installation\" bcdedit /set {newguid} device
vhd=\[D:\]Image.vhd bcdedit /set {newguid} osdevice vhd=\[D:\]Image.vhd
bcdedit /set {newguid} detecthal on
Fore more information about bcedit command see the following link http://www.sevenforums.com/tutorials/2676-bcdedit-how-use.html http://technet.microsoft.com/en-us/library/dd799299(v=ws.10).aspx DiskPart help