• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 350
  • Last Modified:

Booting from a VHD on a clean formatted drive

I created a bootable vhd on my reference computer (only os on the machine not dual boot).  How can I copy this vhd file from reference computer to another pc with a blank hard drive and get it to boot? Is this possible?  If it is, do I use bcdedit to do it.  What would the command look like.  

all help is appreciated.
0
maquet
Asked:
maquet
  • 2
  • 2
1 Solution
 
kirankkhblCommented:
try this

bcdedit.exe  /create /application osloader
it will give {ID}

bcdedit.exe  /set {ID} device vhd=[D:]\VHD\WIN2008STD.vhd        
Path of vhd

bcdedit.exe  /set {ID} path \Windows\system32\winload.exe

bcdedit.exe  /set {ID} osdevice vhd=[D:]\VHD\WIN2008STD.vhd
Path of vhd

bcdedit.exe  /set {ID} systemroot \Windows

bcdedit.exe  /set {ID} description "Windows 2008R2 STD VHD"

bcdedit.exe  /displayorder {ID} /addlast
0
 
maquetAuthor Commented:
I get:

The boot configuration data store could not be opened. The requested system device cannot be found.

Let me detail things out.
1. I built a booting vhd on machine a
2. I boot machine a from usb stick and copied the vhd to external hard drive
3. I attached the usb boot stick and external hd to another machine.
4. I boot from usb stick and used diskpart to clean the internal hd.
5. I used diskpart to create primary partition, format it, assign letter c to the drive
6. I copied the vhd file from the external drive.
0
 
kirankkhblCommented:
it will not work
first install OS try the above steps
0
 
maquetAuthor Commented:
That kind of defeats the purpose.  I don't want to reinstall the OS.  Everything I have on the vhd is the way I want the 2nd machine to look.
0
 
d_nedelchevCommented:
If you can boot to some kind of WinPE like the native "Recovery Environment" of NT 6.x you can try using BootICE (http://bootice.narod.ru/). It's a single exe file. Once you boot the machine in to WinPE just start the program and go to the "BCD Edit" tab.

It has very simple and convenient interface. Just use the "Add" button and edit the details (NOTE that by default it sets the "Language" to zh-CN. I'm not sure if that would cause any problems but just in case).

Make sure that you have "BOOTMGR" in the root folder of the bootable partition and the created or edited "BCD" file is in "Boot" folder in the root of that same partition e.g. "C:\Boot\BCD"
0

Featured Post

Vote for the Most Valuable Expert

It’s time to recognize experts that go above and beyond with helpful solutions and engagement on site. Choose from the top experts in the Hall of Fame or on the right rail of your favorite topic page. Look for the blue “Nominate” button on their profile to vote.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now