Skip to content

add support for newer systemrescuecd isos on grub2 (wip) #543

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 78 additions & 0 deletions data/multibootusb/grub/menus/systemrescuecd.d/generic-new.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
for isofile in $isopath/systemrescue-*.iso; do
if [ -e "$isofile" ]; then
regexp --set=isoname "$isopath/(.*)" "$isofile"
submenu "$isoname ->" "$isofile" {
iso_path="$2"
loopback loop "$iso_path"
menuentry "Default boot options" {
bootoptions="isoloop=$iso_path scandelay=1"
if cpuid -l; then # Check whether CPU is 64-bit
linux (loop)/sysresccd/boot/x86_64/vmlinuz $bootoptions
else
linux (loop)/sysresccd/boot/i686/vmlinuz $bootoptions
fi
initrd (loop)/sysresccd/boot/intel_ucode.img /sysresccd/boot/amd_ucode.img /sysresccd/boot/x86_64/sysresccd.img
}
menuentry "All files cached to memory (docache)" {
bootoptions="isoloop=$iso_path docache"
if cpuid -l; then # Check whether CPU is 64-bit
linux (loop)/sysresccd/boot/x86_64/vmlinuz $bootoptions
else
linux (loop)/sysresccd/boot/i686/vmlinuz $bootoptions
fi
initrd (loop)/sysresccd/boot/intel_ucode.img /sysresccd/boot/amd_ucode.img /sysresccd/boot/x86_64/sysresccd.img
}
menuentry "Framebuffer console in high resolution" {
bootoptions="isoloop=$iso_path nomodeset vga=791"
if cpuid -l; then # Check whether CPU is 64-bit
linux (loop)/sysresccd/boot/x86_64/vmlinuz $bootoptions
else
linux (loop)/sysresccd/boot/i686/vmlinuz $bootoptions
fi
initrd (loop)/sysresccd/boot/intel_ucode.img /sysresccd/boot/amd_ucode.img /sysresccd/boot/x86_64/sysresccd.img
}
menuentry "Do not ask for keyboard, use US keymap" {
bootoptions="isoloop=$iso_path setkmap=us"
if cpuid -l; then # Check whether CPU is 64-bit
linux (loop)/sysresccd/boot/x86_64/vmlinuz $bootoptions
else
linux (loop)/sysresccd/boot/i686/vmlinuz $bootoptions
fi
initrd (loop)/sysresccd/boot/intel_ucode.img /sysresccd/boot/amd_ucode.img /sysresccd/boot/x86_64/sysresccd.img
}
menuentry "Boot an existing Linux system installed on the disk" {
bootoptions="isoloop=$iso_path root=auto"
if cpuid -l; then # Check whether CPU is 64-bit
linux (loop)/sysresccd/boot/x86_64/vmlinuz $bootoptions
else
linux (loop)/sysresccd/boot/i686/vmlinuz $bootoptions
fi
initrd (loop)/sysresccd/boot/intel_ucode.img /sysresccd/boot/amd_ucode.img /sysresccd/boot/x86_64/sysresccd.img
}
menuentry "Alternative kernel with default boot options" {
bootoptions="isoloop=$iso_path scandelay=1"
if cpuid -l; then # Check whether CPU is 64-bit
linux (loop)/isolinux/altker64 $bootoptions
else
linux (loop)/isolinux/altker32 $bootoptions
fi
initrd (loop)/sysresccd/boot/intel_ucode.img /sysresccd/boot/amd_ucode.img /sysresccd/boot/x86_64/sysresccd.img
}
menuentry "Directly start the graphical environment" {
bootoptions="isoloop=$iso_path dostartx"
if cpuid -l; then # Check whether CPU is 64-bit
linux (loop)/sysresccd/boot/x86_64/vmlinuz $bootoptions
else
linux (loop)/sysresccd/boot/i686/vmlinuz $bootoptions
fi
initrd (loop)/sysresccd/boot/intel_ucode.img /sysresccd/boot/amd_ucode.img /sysresccd/boot/x86_64/sysresccd.img
}
submenu "System Tools ->" {
menuentry "MEMTEST: Memory test using Memtest86+" {
bootoptions="-"
linux16 (loop)/sysresccd/boot/memtest $bootoptions
}
}
}
fi
done