[virt-tools-list] windows7 bcd boot configuration

Richard W.M. Jones rjones at redhat.com
Fri Jan 13 16:08:42 UTC 2012


On Fri, Jan 13, 2012 at 11:12:33AM -0200, Itamar Reis Peixoto wrote:
> I am trying to automate the deployment of  windows7 + fedora  using
> anaconda / kickstart ( 100+ machines )
> 
> in %pre section of anaconda kickstart I do this.
> 
> wget --no-proxy -qO - http://192.168.7.254/itamar/web/windows7.img.gz
> | gunzip -c | dd of=/dev/sda1 bs=64k
> ntfsresize -f /dev/sda1 <<< y
> 
> the image is  restored  well , but windows doesnt boot, ->

With any particular error message?

In any case the most likely problem is that you can't just unpack a
Windows disk image into a partition and expect it to work.  You have
to adjust a few bytes in the NTFS header to make it work, as
virt-resize does:

https://github.com/libguestfs/libguestfs/blob/master/resize/resize.ml#L1048

The gory details are here:

http://thestarman.pcministry.com/asm/mbr/NTFSBR.htm

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
New in Fedora 11: Fedora Windows cross-compiler. Compile Windows
programs, test, and build Windows installers. Over 70 libraries supprt'd
http://fedoraproject.org/wiki/MinGW http://www.annexia.org/fedora_mingw




More information about the virt-tools-list mailing list