
Contents
- How to make an E2B USB drive using linux
- How to update E2B
- BIOS compatibility
- agFM for UEFI booting
- Add Ventoy (optional)
- Copying files
- File Extensions and 'Auto-suggest'
- Making files contiguous (defrag)
- CONTIG.ISO
- ISOBOOT
- Creating files containing ext2/3/4 filesystems for persistence
- Test using QEMU under linux
- UEFI support
- Restore E2B partitions under Linux
How to make an E2B USB drive using linux
The .sh scripts provided will format an existing partition, then it will copy the E2B files onto it and then run bootlace to install grub4dos:
- Download and unzip the Easy2Boot .ZIP file to a folder on your internal linux hard disk - use Desktop GUI or 7Zip to extract the files (sudo apt-get install 7zip).
- Open a Terminal session at the new \_ISO\docs\linux_utils folder (contains utilities and scripts)
- Use chmod to make the files in linux_utils executable (sudo chmod 777 *)
-
Type ./fmt.sh or ./fmt_ntfs.sh (this requires the bash shell - if you are using the sh shell you will get errors - or try sudo bash ./fmt.sh)
Note: be sure to select the correct partition such as sdb1 or you will get a 'MISSING MBR HELPER' error message when you boot!).
Note: if you get a 'permission denied' error, precede the command with sudo.Password 'e2b' may be requested.
Read the ReadMe file in the \_ISO\docs\linux_utils folder for more details and see the article on www.rmprepusb.com #114 or my blog post here.To format a partition as NTFS, use instead the fmt_ntfs.sh script and use the 32-bit executable udefrag to defrag the files (E2B v1.83+)
- Use defragfs on FAT32 volumes.
- Use udefrag -qm /dev/sdX1 for NTFS volumes, where X is the device letter, e.g. /dev/sdb1 (see ReadMe file in linux_utils folder).
- Add the ISO as an extra USB partition (ISO file must be contiguous)
- Copy a non-contiguous ISO to a contiguous file (CONTIG.ISO) using dd and then use method 1 above
- Try to identify the type of linux ISO from it's file name and use linux cheat codes to boot from ISO (isoboot)
How to update E2B
rsync -auv E2Bnew/ /myUSBdrive/
agFM for UEFI booting
Add Ventoy
- Ventoy does not require the payload files to be contiguous.
- You can Secure UEFI64-Boot to Ventoy by first booting to agFM.
1. Update your E2B files to v2.05 or later
2. Update the agFM files on partition 2 (download - unzip - overwrite all files on partition 2 with the new files) - must use agFM v1.57 or later
3. You now need to add the Ventoy files (latest version e.g. 1.0.20).
First make a new folder E2B_VENTOY on your computer somewhere...
4a. If you have made a Ventoy USB bootable drive already, copy all the files and folders from partition 2 of the Ventoy USB drive to the new E2B_VENTOY folder.
-- OR --
4b. If you don't have a Ventoy USB drive available, then download the latest Ventoy Windows release as a .zip file.
Open the zip file using 7zip and open the ventoy.disk.img folder (e.g. \ventoy-1.0.20 -ventoy - ventoy.disk.img.xz - ventoy.disk.img
Extract all the folders to the empty E2B_VENTOY folder (four folders in all)
- ventoy
- tool
- grub
- EFI
5. We need to change some files in these new E2B_VENTOY folders:
The Certificate file ENROLL_THIS_KEY_IN_MOKMANAGER.cer can be deleted.
Go to the E2B_VENTOY\EFI\BOOT folder...
If the file \grubx64_real.efi exists then rename it to ventoyx64.efi - OR -
If the file \grubx64_real.efi does NOT exist (there will only be bootx64.efi present) then rename the file BOOTX64.efi it to ventoyx64.efi
Delete all other files in the E2B_VENTOY\EFI\BOOT folder (if any) EXCEPT for the file ventoyx64.efi
6. Go to https://github.com/ventoy/Ventoy/blob/master/INSTALL/grub/i386-pc/core.img and add this file to the ventoy folder.
7. Your E2B_VENTOY folder should now contain these new files (amongst the old files\folders)...
E2B_VENTOY\EFI\BOOT\ventoyx64.efi (used for UEFI64 booting - only file in this folder)
E2B_VENTOY\ventoy\core.img (used for Legacy\MBR BIOS booting)
8. Now simply copy the entire contents of the E2B_VENTOY folder to the root of the 2nd partition of your E2B USB drive which should already contain agFM boot files. You should not be prompted to overwrite any existing files on the USB drive - if you are then you did something wrong! Do NOT overwrite any existing files when you add the E2B_VENTOY files. Check your 2nd partition now has a new /tool folder (as well as /ventoy, /grub and /EFI + others).
Copying payload files
Tip: Never download an ISO directly onto the USB drive because the file may be heavily fragmented (due to multiple download threads being used). Always download the ISO to your internal hard disk first and then copy it to the USB drive.
Making files contiguous

sudo perl ~/Downloads/Easy2Boot/_ISO/docs/linux_utils/defragfs /media/Multiboot -f
sudo ./udefrag -om /dev/sdb1
sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install libc6:i386 libncurses5:i386 libstdc++6:i386
and then run udefrag...
(change to _ISO/docs/linux_utils folder) sudo chmod 777 * sudo ./udefrag -om /dev/sdX1 (where sdX1 is your NTFS USB partition) - use -qvm instead of -om for quicker optimisation.
Type "fsck -t ntfs --kerneldefrag /dev/sdX1" without quotes. Replace "sdX1" with the drive letter of your E2B disk.
Wait...
You may aso try to compile a later version of udefrag if you wish UltraDefrag for Linux (untested).
CONTIG.ISO
ISOBOOT
File Extensions and 'Auto-suggest'
BIOS Compatibility
Creating files containing ext2/3/4 filesystems for persistence
dd if=/dev/zero of=mint-rw bs=1M count=1024
mkfs -t ext2 mint-rw -L casper-rw
mkfs.ext3 -F mint-rw -L casper-rw
Making a sparse file using dd may be faster (untested), try this... dd if=/dev/zero of=casper-rw bs=1M count=0 seek=1024
CreatePersistentImg.sh
sh CreatePersistentImg.sh [ -s SIZE_IN_MB ] [ -t FSTYPE ] [ -l LABEL ] [ -c CFG ] for example:sh CreatePersistentImg.sh ----> persistence.dat in 1GB size and ext4 filesystem and casper-rw labelsh CreatePersistentImg.sh -l MX-Persist ----> persistence.dat in 1GB size and ext4 filesystem and MX-Persist labelsh CreatePersistentImg.sh -s 2048 ----> persistence.dat in 2GB size and ext4 filesystem and casper-rw labelsh CreatePersistentImg.sh -s 4096 -t xfs ----> persistence.dat in 4GB size and xfs filesystem (ext2/3/4 xfs are supported) and casper-rw labelsh CreatePersistentImg.sh -l persistence -c persistence.conf ----> persistence.dat in 1GB size and ext4 filesystem and persistence label. Finally will create apersistence.conf file inside the persistence.dat. The file only has 1 line "/ union". Some distros have this requirement (e.g. Debian/Kali/CloneZilla...)
Testing using QEMU under linux
2. Boot using qemu-system-x86_64
sudo qemu-system-x86_64 -machine accel=kvm:tcg -m 512 -hda /dev/sdc
"/dev/sdc" is the usb device as listed by fdisk, 512 is the amount of memory to allocate.
UEFI support
If you want to try UEFI-booting to ISOs then add the agFM files to the second FAT32 partition (E2B v2).
Restore E2B partition after booting to Linux from a .imgPTN file (E2B v1.A9+)
IMPORTANT: Very little checking is done by the script - make sure you select the correct drive!
.imgPTN files
Recommended for Easy2Boot (fastest flash drive!)
SanDisk Extreme SDCZ880-128G-G46
- Home
- Start & Intro
- Quick Setup Guide >>>
- DOWNLOADS >>>
- YouTube videos
- Tutorials and How To's
-
Make a USB Drive >>>
- Make a multi-partition E2B USB drive using RMPrepUSB
- Use an existing USB HDD for E2B
- Use LINUX to make an E2B drive + defrag
- How to Update E2B
- How to make a WINHELPER USB Flash Drive (fix 'Required DVD drive driver is missing')
- Multiple partitions on a USB Flash drive
- Using other partitions or drives
- Backup/Restore/Copy (clone) any E2B USB drive
- Make and burn an E2B DVD
- Using E2B with a Zalman/IODD
- Add E2B to your own grub4dos USB drive
- How to remove E2B
- E2B Menu System
- UEFI booting from E2B
-
How to add Payload Files and Use E2B >>>
- Make files CONTIGUOUS
- File Extensions recognised by E2B
- UEFI+MBR and how to make .imgPTN files
- MakePartImage and how to change the CSM Menu
- UEFI-Multiboot and rEFInd
- Using SWITCH_E2B with .imgPTN files
- Using the \_ISO\AUTO folder
-
WINDOWS payloads >>
- E2B USB HDD - Installing Windows with a 'WinHelper' drive
- Windows XP Install ISOs
- Install XP 32-bit + disk drivers (DPMS)
- Windows XP 64-bit
- Install XP using WinPE (one step process)
- Add XP Install ISOs using WinSetupFromUSB
- Windows Vista/7 Install ISOs
- UEFI boot from Windows 7 Install ISOs
- Windows 8/10 Install ISOs
- Unattended Installs
- XMLtoE2B.exe (Unattend.XML files)
- Adding >4GB Windows Install ISOs using .imgPTN files
- Automating Windows Installs from .imgPTN files
- Split_WinISO
- Add Windows ISOs to partition 2
- Windows AIO ISOs
- WindowsToGo
- WinNTSetup
- WinLite10 XML files
- SDI_CHOCO (install drivers, apps and updates) >>
- .VHD and .WIM files
- PassPass (bypass the Windows Password)
- Hack Windows Account Passwords (UtilMan.exe)
- Windows 2000
- Windows 98
- Multipoint Server
- Add the latest XP drivers (DPMS)
- Add a Windows Install menu entry
- LINUX payloads >>
- MSDart ERD ISOs
- WinBuilder, Medicat, Gandalf and WinPE ISOs
- Hirens/Strelec/DLC/F4 ISOs
- DOS (MS-DOS and FreeDOS)
- HAIKU
- MAC OS X
- FreeBSD
- MOVE_IMGPTN
- List of tested ISOs\payloads (with instructions)
-
Configure E2B >>>
- Menu settings (quick reference)
- E2B Menu Demo
- E2B_Editor
- E2B files and folders explained
- MyE2B.cfg - E2B configuration file >>
- Change the payload menu entries and help text using a .txt file
- Change the order of the menu entries
- Change the background wallpaper
- Different background wallpaper for each menu
- Default Menu and Timeout
- Change the Language, Headings, Menu and text
- Changing the default E2B menu entry order
- 'Change File Extension' prompt (Auto-Suggest)
- Change the Keyboard Layout
- About .mnu files
- Sample .mnu files
- PimpMyDrive.cmd
- Reduce the E2B messages
- Add a new Sub-Menu folder
- Stamps, Animation and Tunes
- Draw lines and boxes on the screen
- Write text/time/date to the menu screen
- Global Hotkeys
- Themes (Skins)
- Fonts
- Speeding up E2B (inc. FASTLOAD)
- One Single Menu
- The E2B F1 Help menu
- Add your own Help Menu
- Add Help text files (.help)
- Add Windows Install ISOs to the Main Menu
- Change the Windows Install Menu
- Passwords and Security
- Hide Payloads and Menu Entries
- Guest Mode
- GFX Boot Menus
- Dual Booting
- Change the CSM .imgPTN Menu
- Configure Clover
- Right-to-Left Languages
- Create new language files
- How to modify LOADISO.CMD (Repair message)
- Count number of boots
- UEFI - useful things know!
-
FAQ, Info, TroubleShooting, QEMU and Virtual Machines >>>
- 'File Not Contiguous' and 'Too Many Fragments' Errors
- 137GB 'BAD BIOS' bug
- TroubleShooting E2B
- E2B Error Messages
- Grub4dos Error Numbers
- Common problems with payload files
- Repair a corrupt E2B drive
- Known Issues and Bugs
- Slow and buggy BIOSes
- How E2B Works
- QEMU and Virtual Machines >>
- Using VBOX with a WinHelper USB drive
- Debugging E2B
- CONTIG.ISO
- ISOBOOT
- WIMBOOT (iPXE)
- grub4dos
- Useful resources
- Removable v. Fixed
- Gallery
- Guestbook
- Forum
- Blog
- a1ive grub2 File Manager (MBR+UEFI)
- Add Ventoy
- Site Map
- eBooks
- Contact Me >>>
- Donate
- Licensing
- Privacy policy (GDPR)
- Bespoke design service
- Grub2 Menu System (UEFI_GRUB2_PTN2)