Cannot boot from Vhd

Feb 24, 2010 at 4:39 PM

Hey ken,

i try to create a bootable Windows7 Vhd using DiskUtils but i can't get it working. For example VirtualBox gives me this "Fatal: No bootable medium found! System halted."

I create a new VHD with one NTFS partition on it. The partition is set as active partition.

Then i copy Windows7 to the Vhd and make Windows bootable using the BcdBoot.exe.

Coordinator
Feb 26, 2010 at 7:28 PM

Hi Stefan,

You need to make sure you have put the MBR and Windows boot loader on the disk.  The OSClone sample utility shows how to do this.

 

Cheers,

Ken

Feb 27, 2010 at 7:10 AM

I tried adding the MBR and the boot loader but i still get the same message. I also tried to attach the vhd and write the mbr using the bootsect.exe from MS without success.

I never got that message before. I tried to create the Vhd using the windows api and format it with diskpart.exe then it works fine.

Coordinator
Feb 27, 2010 at 8:50 AM

Hi Stefan,

I can't reproduce the problem.  Can you try running the OS Clone utility, and report back on whether it creates a bootable disk:

OSClone.exe -sz 50GB -of VHD-dynamic <inputdisk> <outputdisk>

Thanks,

Ken

Mar 1, 2010 at 10:48 AM

Hey stefanrtr,

you know that seven has a extra partition (with no driveletter assigned), which is used for the boot process. I think not copying this partition is your problem as the bootloader searches this partition afaik.
The hidden partition is a standard NTFS Partition which holds the BCD stuff, so for seven you will need to copy this partition too and change the BCD stuff hold there to point to the correct Boot partition.

Hope this helps.

Ciao Ephraim

Mar 2, 2010 at 6:49 AM

Hey Ephraim,

i dont' think that is the issue because it works then i create and format the Vhd using the WindowsApi.

Mar 2, 2010 at 7:44 AM

Hey Stefanrtr,

in that case I gues it is the NTLDR section missing ...

Windows doesn't boot with only MBR and BootSector, after the BootSector are 8 Sectors with NTLDR data (for XP only 6 Sectors) which you will need to copy too ...

So you need to copy

  • the first Sector of the disc => MBR,
  • the first Sector of the partition => VBR (or Bootsector)
  • the 8 Sectors following the VBR => NTLDR Section

This site helped me a lot with this issue: http://mirror.href.com/thestarman/asm/mbr/VistaVBR.htm (especially search for "The eight physical sectors")

Ciao Ephraim