Friday, 30 November 2018

About E2B v1.A7g and using the 2nd partition on the E2B drive for payload files

If you have a large (>128GiB) USB hard disk, I recommend that you use the first partition (up to 128GiB in size) for E2B and use the second partition for other purposes such as for storing utilities, hard disk backups, documents, etc. Note that only  recent versions of Windows 10 (1703+) can access the 2nd partition if it is on a Removable (flash) drive.

However, you can place most payloads such as linux .ISO files, Windows VHD files, etc. on the second partition and add the PTN2_MNU.mnu menu file to one of the menu folders (e.g. add it to \_ISO\MAINMENU). The PTN2_MNU.mnu will take you to a sub-menu where all the files in the folder on the second partition will be listed and you can then boot to any one of them.

Note: Windows VHD files will only boot from partition 2 on a Removable USB drive if the VHD contains Windows 10 1703 or later. However, there should be no restriction if the USB is a hard disk.

The 128GiB USB BIOS bug
Note that due to some BIOSes (e.g. Asus EeePC's) having a bug in their USB driver, they are not able to access files past 128GiB on the USB drive. This bug is quite common, especially on older USB 2.0 only systems. This means that grub4dos will not be able to access the file if it has a sector address higher than 128GiB on the disk. This is why I suggest you do not use a USB drive larger than 128GiB - or at least keep the E2B partition below 128GiB in size.

If the file is beyond 128GiB on the drive (e.g. in a 2nd partition on a >128GiB USB drive) then grub4dos may be unable to access it.

E2B will warn you if the BIOS has this 128GiB bug as soon as it starts to load.

Sometimes, you can fix the BIOS bug by loading the grub4dos USB 2.0 driver which replaces the buggy BIOS driver (hold down the SHIFT key just as E2B starts to boot to load the grub4dos USB driver). However, the grub4dos USB 2.0 driver only works on older USB 2.0 systems and not with newer chipsets or USB 3.0.

Tip: If your system has this BIOS bug but does not have any USB 2.0 ports and you have a USB 3.0 E2B drive, then connect the E2B drive to a USB 3.0 port using a USB 2.0 cable - this may allow the grub4dos USB 2.0 driver to work because it will use the USB 2.0 connections instead of the USB 3.0 set of contacts.

Windows ISOs
You may have noticed that I said that you can place most payloads on the second partition - well  Windows Install ISOs were an exception, but not now!

I have tweaked E2B v1.A7g so that you can, if you wish, add Windows Install ISOs onto the second partition (all types of Windows ISOs - except XP ISOs).

Here is how the 'cheat' works...


You can follow the instructions here.  Basically, to get the ISO files on partition 2 to be listed in the Windows menu, you have to also create a small 'dummy' file of the same name in the same Windows sub-folder on the E2B first partition. e.g.

Partition 1
\_ISO\WINDOWS\WIN10\Win10x64.iso    (non-zero size dummy file - any contents)
Partition 2
\_ISO\WINDOWS\WIN10\Win10x64.iso    (5GB - the real ISO)

Now you can select the ISO from the Windows menu as usual (all .iso files will be listed), but E2B will detect if there is an identically named ISO on the 2nd partition and will use that instead. E2B will also prompt you with a list of the .xml and .key files that are present in the same folder on the second partition if the selected ISO is on the second partition.

Note that only recent versions of Windows 10 (and non-buggy BIOSes) will be able to access the 2nd partition of a Removable USB drive, so if your E2B drive is of the Removable type, this procedure will only work if the ISO contains a recent (2017/18) version of Windows 10 (1703 or later).

If your E2B USB drive is of the 'Fixed-disk' type, then you will need to also connect a WinHelper Removable USB drive (as usual).

You can add a .mnu file to directly boot to any Windows ISO on the 2nd partition (see here for details).

There is also a way you can actually install Windows from an E2B USB drive which has a 'True Hidden'  E2B first partition.  A 'True Hidden' partition is inaccessible from Windows (but not by linux) but you can still boot to E2B from the USB drive and still run most payload files (except some Windows/WinPE payloads). However, you can now install Windows using a 'True Hidden' E2B drive plus a Windows Install ISOs on partition 2 if you really want to! The same restrictions for using an E2B Removable drive  with Windows 10 1703+ and using a non-buggy BIOS still apply however.

Note: as long as the ISOs on partition 2 are not too fragmented, there is no need to make them contiguous.

If you have any problems with this version, please let me know and then 'down-date' to a previous version.