Monday, 31 December 2018

E2B v1.A8a Beta available

Booting Windows install ISOs no longer requires an extra WinHelper USB flash drive!

If your E2B USB drive was a 'fixed disk' then previous versions of E2B required you to also connect a WinHelper USB Flash drive to the system because on all versions of Windows NT6 (Vista to Win10 1609) the \AutoUnattend.xml file had to be on a 'Removable' USB drive in order for Windows Setup to detect and use the XML file.

The alternative was to convert the ISO to a .imgPTN file.

This new version of E2B uses 'wimboot' which is part of the open source iPXE project here.

The latest versions of wimboot allow you to 'inject' files into the boot image (X: volume) without actually having to alter the boot.wim file.

This means that we can force WinPE to run Setup, load the ISO file and use any XML file we wish.

It also means that we do not need to modify the XML file to add in the special 'RunSynchronous' command that was previously required by E2B. If you wish you could use unmodified XML files generated by the WAFG site.

E2B v1.A8a uses the wimboot method for Vista through to Server2019 install ISO files. However, E2B will still allow you to use the 'old' method (which requires a Removable drive for pre-Win10_1703 ISOs).

If you press [ENTER] within 3 seconds when prompted, it will not use the new Wimboot method.

Wimboot advantages
1. Does not require a 'RunSynchronous' section in an XML file.
2. Does not require E2B to be on 'Removable' media or require you to add a WinHelper USB drive.

WimBoot disadvantages
1. Requires a system with more RAM (probably 2GB minimum but depends on the size of the boot.wim file).
2. We must pick one specific image inside the boot.wim to boot from. Usually image 1 in a boot.wim file is the Recovery Image and image 2 is the Setup WinPE image, so E2B always tries to boot to image 2.
3. Wimboot may not be compatible with some All-in-One ISOs (so must convert it to an .imgPTN file).
4. Only works for boot.wim based ISOs (not XP-based ISOs).
5. Not as fast as directly booting from the ISO.
6. LOADISONP is always used so no Repair\Recovery options are offered (doesn't work well anyway in Win8/10!).

How wimboot works

Below is a sample of a grub4dos menu using wimboot with a Windows 10 ISO.

title Install Windows10x64UK_Oct_2018 using wimboot method
map /Windows10x64UK_Oct_2018.iso (0xff)
map --hook
root (0xff)
# the root path now points to the files inside the ISO file
# hd0,0 is the USB drive that we booted from
kernel (hd0,0)/wimboot index=2
initrd @startup.bat=(hd0,0)/startup.bat @winpeshl.ini=(hd0,0)/winpeshl.ini @bootmgr=/bootmgr @bcd=/boot/bcd @boot.sdi=/boot/boot.sdi @boot.wim=/sources/boot.wim

When image 2 of the boot.wim file boots, the startup.bat and winpeshl.ini files will be 'injected' into the X:\Windows\System32 folder automatically!

Thus when WinPE starts, it will execute the command(s) that we have placed in winpeshl.ini which, in turn, will cause it to run the startup.bat file.

The startup.bat file can contain lines of code which will load the Windows ISO file as a virtual DVD using ImDisk so that Windows Setup can access the \sources\install.wim file (or .esd file) inside the ISO.

E2B v1.A8a uses a similar technique to that used in the menu above in it's grub4dos batch files. It also takes care to remove the RunSynchronous section from the XML file if it exists because otherwise it would try to load the ISO as a virtual drive twice.

No comments:

Post a Comment