Her er indholdet af min bat file der danner bcd filen til når jeg PXE'er en windows installation igang via MDT og LiteTouchPE wim filerne.

Hvordan min linux PXE server er sat op, kan læses her: http://www.net-help.dk/index.php/debian/103-pxeboot-winpe-med-tftp-hpa

Bcdedit /createstore c:\BCD

REM PR winpe

Bcdedit /store c:\BCD /create {ramdiskoptions}
Bcdedit /store c:\BCD /set {ramdiskoptions} ramdisksdidevice  boot
Bcdedit /store c:\BCD /set {ramdiskoptions} ramdisksdipath  \Boot\boot.sdi
REM Bcdedit /store c:\BCD /create /d “Windows X64 Install” /application osloader

REM GUID SJOV
for /f "tokens=3" %%A in ('Bcdedit /store c:\BCD /create /d "Windows X64 Install" /application osloader') do set guid1=%%A

Bcdedit /store c:\BCD /set %guid1% systemroot \Windows
Bcdedit /store c:\BCD /set %guid1% detecthal Yes
Bcdedit /store c:\BCD /set %guid1% winpe Yes
Bcdedit /store c:\BCD /set %guid1% osdevice ramdisk=[boot]\Boot\LiteTouchPE_x64.wim,{ramdiskoptions}
Bcdedit /store c:\BCD /set %guid1% device ramdisk=[boot]\Boot\LiteTouchPE_x64.wim,{ramdiskoptions}

REM PR winpe

REM Bcdedit /store c:\BCD /create {ramdiskoptions} /d "Windows X86 Install"

Bcdedit /store c:\BCD /set {ramdiskoptions} ramdisksdidevice  boot
Bcdedit /store c:\BCD /set {ramdiskoptions} ramdisksdipath  \Boot\boot.sdi
REM Bcdedit /store c:\BCD /create /d “Windows X86 Install” /application osloader

REM GUID SJOV
for /f "tokens=3" %%B in ('Bcdedit /store c:\BCD /create /d "Windows X86 Install" /application osloader') do set guid2=%%B

Bcdedit /store c:\BCD /set %guid2% systemroot \Windows
Bcdedit /store c:\BCD /set %guid2% detecthal Yes
Bcdedit /store c:\BCD /set %guid2% winpe Yes
Bcdedit /store c:\BCD /set %guid2% osdevice ramdisk=[boot]\Boot\LiteTouchPE_x86.wim,{ramdiskoptions}
Bcdedit /store c:\BCD /set %guid2% device ramdisk=[boot]\Boot\LiteTouchPE_x86.wim,{ramdiskoptions}

REM  PR menu

Bcdedit /store c:\BCD /create {bootmgr}
Bcdedit /store c:\BCD /set {bootmgr} timeout 30
Bcdedit /store c:\BCD /displayorder %guid1% %guid2%


Jeg har lavet mit script udfra denne Technet Artikel: http://technet.microsoft.com/en-us/library/cc722358(v=ws.10).aspx

Dog er der et par ting man skal være opmærksom på:

at "" er de rigtige

/d "tekst" de forkerte steder kan overskrive de navne der angives pr images, dvs. man skal gætte sig til hvilket image som er x86 og x64

- skal ændres til /  dvs. -store skal være /store på bcdedit kommandoerne

Path og wim file navne tror jeg faktisk er Case sensative i BCD filen.

bcdedit /store C:\BCD /enum   er en god kommando til at se hvad man har lavet, via scriptet.

Nu kan jeg deploy en fuld Windows 7 pro X64 klient, incl basic apps på ca. 30 minutter, via hobby gigabit netværk, med low end virtuelt mdt2012 server.