I'm trying to work out the 'best' way to specify that I want a certain GRUB (v2.03) menu entry to look for its savefile in a specific location... and while I have an answer, it's often suggested as not being the' best' or 'most reliable' way...
The menu entry:
Code: Select all
menuentry "Puppy Linux: grumpy: VirtualBox: F96-CE (on nvme0n1p3)" {
insmod fat
search --no-floppy --fs-uuid --set=root 0A34A4BC34A4ABDF
echo "Loading vmlinuz"
# The following works Ok... but presents a menu of files to load
linux /Puppy/F96-CE/vmlinuz pmedia=atahd pdrv=Windows psubdir=/Puppy/F96-CE pfix=fsck
# fails: linux /Puppy/F96-CE/vmlinuz pmedia=atahd pdrv=Windows psubdir=/Puppy/F96-CE pfix=fsck psave=fossapup64save-GRUMPY-VM-PROD.4fs
# fails: linux /Puppy/F96-CE/vmlinuz pmedia=atahd pdrv=Windows psubdir=/Puppy/F96-CE pfix=fsck psave=Puppy/F96-CE/fossapup64save-GRUMPY-VM-PROD.4fs
# fails: linux /Puppy/F96-CE/vmlinuz pmedia=atahd pdrv=Windows psubdir=/Puppy/F96-CE pfix=fsck psave=UUID=0A34A4BC34A4ABDF:/Puppy/F96-CE/fossapup64save-GRUMPY-VM-PROD.4fs
# fails: linux /Puppy/F96-CE/vmlinuz pmedia=atahd pdrv=Windows psubdir=/Puppy/F96-CE pfix=fsck psave=UUID=b16aa104-463a-45c0-8cc6-45ed5fdc9b5c:/Puppy/F96-CE/fossapup64save-GRUMPY-VM-PROD.4fs
# WORKS! linux /Puppy/F96-CE/vmlinuz pmedia=atahd pdrv=Windows psubdir=/Puppy/F96-CE pfix=fsck psave=nvme0n1p3:/Puppy/F96-CE/fossapup64save-GRUMPY-VM-PROD.4fs
# fails: linux /Puppy/F96-CE/vmlinuz pmedia=atahd pdrv=Windows psubdir=/Puppy/F96-CE pfix=fsck psave=UUID=0A34A4BC34A4ABDF:Puppy/F96-CE/fossapup64save-GRUMPY-VM-PROD.4fs
if [ -e /Puppy/F96-CE/local-initrd.gz ]; then
set local_rd=/Puppy/F96-CE/local-initrd.gz
else
set local_rd=
fi
if [ -e /Puppy/F96-CE/ucode.cpio ]; then
set ucode_rd=/Puppy/F96-CE/ucode.cpio
echo "Loading ucode.cpio and initrd.gz"
else
set ucode_rd=
echo "Loading initrd.gz"
fi
initrd $ucode_rd /Puppy/F96-CE/initrd.gz $local_rd
}
I get a bit confused with psave
, pdrv
, psubdir
and others... The 'normal' kernel parameters seem to be listed, for example, at https://www.kernel.org/doc/html/v4.14/a ... eters.html ...and there is a page on the Puppy wiki ( see https://wikka.puppylinux.com/BootParametersPuppy ) and another in the old forum ( see https://oldforum.puppylinux.com/viewtopic.php?t=35003 )
...but there aren't any 'real world' examples, really, of how the different parameters are used OR how they interact... at least that I could find. For example, why does the psave
with a path work, in which case, the psubdir
is maybe unnecessary, particularly given the location of vmlinuz is fully pathed (off the root device)...? If you specify the psubdir
, shouldn't it be unnecessary anywhere unless another file is located somewhere different?
Does anyone have any thoughts on this?