How to create multiboot USB with Linux - LinuxConfig.org

I was able to get the grub menu to show up as in the given tutorial, but upon selecting an option, I just get a black screen. This occurs on both my fedora and ubuntu ISO’s. I’ve tried additional kernel arguments but they haven’t seemed to resolve this issue. I’ve also tried the flash drives on two machines with the same result, so I think it is certainly the grub.cfg. Any ideas; I’ve tried both the cfg given in this tutorial as well as the one specified in the Ubuntu documentation, all to the same result?

Very nice tutorial, thanks. One thing I noticed is that the the grub2-install line doesn’t work anymore with Ubuntu 20.04 / grub-efi 2.04. I could get it to work for the grub-efi version with grub-install --efi-directory=/media/efi/ --boot-directory=/media/data/boot --recheck --removable. I omitted the x86_64-efi part since it is the default.

Might be worth updating this in the instructions.

Hello, very good article.
It seems I have problem with the grub file. So I am trying to have a multiboot usb key to start some version of the Linux UEFI Validation Tool (hXXXs://01.org/linux-uefi-validation).
This is my cfg file

menuentry “LUV-v2.4-rc2_GPT_x86_64_.img” {
isofile="/boot/iso/LUV-v2.4-rc2_GPT_x86_64_.img"
loopback loop “{isofile}" linux (loop)/isolinux/vmlinuz iso-scan/filename="{isofile}” inst.stage2=hd:LABEL=LUV-v2.4-rc2_GPT_x86_64 quiet
initrd (loop)/isolinux/initrd.img
}

Ideally I should have four files like this to be lunched on a live session at any new boot, but it is nit working. When you have a not common iso, where you can get the parameters to setup?
Thank you.
Salvatore

Excellent how-to - Many thanks! Could you please expand on this statement:

How do we know the directives we should use in a specific case? One way is to mount the image somewhere in our system and take a look at the files placed in the isolinux directory. However, pre-written configuration already exists and are easy to find online.

May I have some more advice or links to details specific to these directives. Specifically, I am trying to create the grub.cfg entry for ClearLinux. But generally knowing how to prepare grub config for any future distro’s iso would be a huge asset to me.

Thank you for sharing your expertise.

Meanwhile, there is a new project which automates making multiboot for a multitude of distros - over 200 at last count. I am not affiliated with the project, but since I wasted some hours on trying to do it myself, I highly appreciate it. Link to project cannot be posted, just google ‘ventoy’.
.Highlights:

  • 100% open source (license)
  • Simple to use (Get started)
  • Fast (limited only by the speed of copying iso file)
  • Directly boot from iso file, no extraction needed
  • Legacy + UEFI supported in the same way
  • UEFI Secure Boot supported (1.0.07+) Notes
  • Persistence supported (1.0.11+) Notes
  • WIM files boot supported (Legacy + UEFI) (1.0.12+) Notes
  • Auto installation supported (1.0.09+) Notes
  • ISO files larger than 4GB supported
  • Native boot menu style for Legacy & UEFI
  • Most type of OS supported, 260+ iso files tested
  • Not only boot but also complete installation process
  • ISO files can be listed in List mode/TreeView mode Notes
  • “Ventoy Compatible” concept
  • Plugin Framework
  • Readonly to USB drive during boot
  • USB normal use unaffected
  • Data nondestructive during version upgrade
  • No need to update Ventoy when a new distro is released

For me, this looks like the future of multiboot. Active project, highly recommended.

How would look menuentry fo Debian 10 netinstall?

THANKS A LOT! This ventoy is great tool, it just works.

thank you,
it works perfectly
I have installed the centos 7 successfully

I’ve had no luck setting up UEFI boot Flash??
This page was my 6th attempt at using web sites that say that do the job.
Some have created a UEFI flash that shows as options, but then the boot fails.
This one didn’t get to that point, since I get an error when trying to go thru steps.
grub2-install: error: this utility cannot be used for EFI platforms because it does not support UEFI Secure Boot.
Comes up on my Fedora 33 machine when I run that step?
Seems Dumb that it would not support doing UEFI without Secure Boot.

Have a project I’ve maintained since 2004 (G4L - Disk imaging Project).
It works fine as a CD boot using syslinux, or can be run from Flash just copied to Flash with dd, or setup with grub4dos on USB. Can even add it to the regular grub2 boot with the 40_custom file.

Basically requires the kernel file (that has EFI options set)
Latest kernel file
9818816 Sep 9 17:15 bz5x13.15
and ramdisk.lzma file that has complete filesystem.
28244926 Sep 9 17:33 ramdisk.lzma
So total about 40M.
The lines from syslinux to load G4L
LABEL bz5x13.15
MENU LABEL ^D: bz5x13.15 x86 09-08-2021
MENU DEFAULT
TEXT HELP
Kernel 5x13.15 from Kernel org
ENDTEXT
LINUX bz5x13.15
APPEND initrd=ramdisk.lzma root=/dev/ram0
lines for Grub4Dos
title G4L
find --set-root /linux/bz5x13.15
kernel /linux/bz5x13.15 root=/dev/ram0
initrd /linux/ramdisk.lzma
lines for the 40_custom file, and putting bz5x13.15 and ramdisk.lzma in boot
menuentry G4L {
linux /bz5x13.15 root=/dev/ram0 telnetd=yes
initrd /ramdisk.lzma
}
So, looking to just do a UEFI boot in similar step from USB?
Have two users, that recently got new machines from Dell and Lenova, and it appears they have complete gotten rid of any type of booting other than UEFI??
Just had an email with Clonzilla developer, and they seemed to give up on doing a direct UEFI boot.
They have a process that sets up another distro live-cd boot, and adds the Clonzilla to it?
With Fedora that would be a 2GB livecd image to get a EFI boot, and then have to add a number of packages that are not included on the livecd that are used by G4L script which is about 2000 lines long.
Seems the UEFI has taking something that works, and made many parts of it not work…
Thanks for any suggestions. A number of options I tried just have one add the ISO, and it sees the ISO file, but then the option fails??
Thanks again.

Amazing, that was a deep dive into some delicious kernel.

As an added challenge, can you think of how you might implement it such that the boot device has a mix of linux and windows images?