Score:-3

Is linux kernel boot parameter root=live:LABEL=$iso a valid option for Ubuntu Live booting, e.g. Lubuntu 20.04 LTS?

in flag

Is linux kernel boot parameter root=live:LABEL=$iso a valid option for Ubuntu Live booting, e.g. Lubuntu 20.04 LTS?

I was making various GNU GRUB 2.04 menu entries to boot into a live session of Lubuntu 20.04 LTS, and it works fine. In my research I found a reference to setting the root of the GNU/Linux environment, but I'm unsure if it would apply to /casper live session booting. I suspect not. I've been using the GNU GRUB loopback loop parameter to do this for 12 years now.

See here: https://man7.org/linux/man-pages/man7/dracut.cmdline.7.html

menuentry "Lubuntu 20.04.3 live no persistence" {
search -n -l T7 -s
set isolabel="Lubuntu 20.04.3"
set isofile=/lubuntu-20.04.3-desktop-amd64.iso
loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile root=live:LABEL=$isolabel ro rd.live.image noeject noprompt
initrd (loop)/casper/initrd

}

The above menu entry works just as well as the below:

menuentry "Lubuntu 20.04.3 live no persistence" {
search -n -l T7 -s
set isofile=/lubuntu-20.04.3-desktop-amd64.iso
loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile ro noeject noprompt
initrd (loop)/casper/initrd

}

Since the url I found this information is a man page for dracut, I suspect the kernel parameter only applies to initramfs images created with dracut.

If so, then the question becomes, was the initramfs found /casper of the above iso created with dracut? Perhaps the source code tree will reveal this.

C.S.Cameron avatar
cn flag
@guiverc: It looks to me like the OP is booting a Fedora Live ISO that is located on a hard drive that is running Ubuntu.
in flag
I have clarified.
in flag
Not Fedora, was just a generic example. edited for clarity.
in flag
@C.S.Cameron Booting a Lubuntu Live ISO located on a different USB drive than the GNU GRUB USB drive found by firmware at boot. Option in firmware boots USB1 with GRUB 2.04 installed, menu item searches for USB2 (label T7) which has ISO of Lubuntu in root directory. Sorry for the confustion.
in flag
@guiverc Thanks, I've never used StackExchange before, but I should know better how to ask a good question. I edited my post to be a question. Sorry to be unclear.
C.S.Cameron avatar
cn flag
I have found that GRUB 2.04 does not boot 20.04 ISO files. I use mkusb to create Live OS that boot using GRUB 2.02. See both: https://askubuntu.com/questions/1269462/bios-uefi-template-image-for-booting-iso-files and https://askubuntu.com/questions/1251729/20-04-booting-iso-from-grub-menu. You can also add `rmmod tpm` to grub.cfg.
in flag
@C.S. Cameron No, it works fine from a USB stick formatted FAT32 on my system. It does use UEFI, but it is from 2014. I did not need to use the rmmod tpm switch.
in flag
@C.S.Cameron Looks like a point release came out yesterday 2/23/2022. Have you tried booting that ISO with GRUB 2.04? 20.04.4?
C.S.Cameron avatar
cn flag
I've been testing 22.04 USB drives lately, I think GRUB is up around 2.06. Have not tried it booting ISO files yet.
in flag
Yes, GRUB is indeed up to 2.06. I found my answer in the casper source tree. Will post here.
in flag
Have you tried a1ive fork of GNU GRUB? http://reboot.pro/index.php?s=ba03ebf1091d7d28a0b71a082488f496&showtopic=22429
in flag
why do people vote down the actual question? This Stack Exchange is very corny with badges and stuff. I vote down Stack Exchange.
Score:1
in flag

The man page for casper answered my question, as well as the source.

http://manpages.ubuntu.com/manpages/focal/en/man7/casper.7.html casper - a hook for initramfs-tools to boot live systems.

It uses initramfs-tools to build the initramfs, not dracut.

Man page and source code for casper in 20.04 shows the casper script has a function named parse_cmdline() which doesn't include root=LIVE:label.

See man page and/or source for all command line options: https://git.launchpad.net/ubuntu/+source/casper/tree/scripts/casper?h=ubuntu/focal&id=30f3fc787f8f977e15b94f639e2fa50a3ae6bdf7

RTFM after all.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.