>>>>> Anton Ertl wrote:
>>>>> Anssi Saari <
a...@sci.fi> writes:
[No idea why Anssi Saari has removed all the Newsgroups: aside of
alt.os.linux.debian from the followup; I've brought alt.os.linux
back just in case.]
[...]
>>> It used to be easier in the good old LILO days.
>> Was it easier? I guess you didn't need chroot with LILO, I vaguely
>> remember carefully setting up a specific config file to install LILO
>> on a specific drive and then running lilo -C to install using that
>> specific config.
> When copying a working system to a new drive, you already had that
> file. You may have had to edit the boot and root partitions in the
> config file on such an operation (and then run lilo), but that was
> certainly much less effort than what you have to do now. In
> particular, I could do it off the top of my head while I cannot do
> that with the current approach, so I have to organize a printout or
> another computer to do it with the current approach.
[...]
I'm not a fan of LILO, but I can't really argue with that.
Personally, while I acknowledge that GRUB has learned some nifty
tricks over the years, such as getting the files from Linux LVM
(and, IIUC, Linux MD RAID), I believe I /can/ afford having a
separate /boot filesystem and a simpler, more robust bootloader.
Such as Syslinux, to which I've switched a few years ago.
(Disclaimer: all my boxes are capable of BIOS/MBR boot; no idea
how well it works with EFI.)
An example configuration is as follows. It's not something,
as a whole, I actually use, but rather a bunch of pieces of
my conffiles all thrown together, for illustrative purposes.
The installation is 3-step: installing the MBR code (mbr.bin,
gptmbr.bin or altmbr.bin) with dd(1), installing the bootloader
proper with syslinux(1), copying any additional files needed
(such as configuration, "help" files, and Syslinux modules.)
So far as I can tell, no chroot(2) is ever necessary.
### extlinux.conf -*- Syslinux -*-
## Syslinux configuration for
dacla.example.com.
## Requires: chain.c32 cmd.c32 ldlinux.c32 ldlinux.sys
## libcom32.c32 libutil.c32 mboot.c32
## Serial console on ttyS0, 9600 8N1. Very handy for systems running
## (booting) under Qemu.
SERIAL 0 9600
DEFAULT dacla-vga
PROMPT 1
TIMEOUT 131
TOTALTIMEOUT 383
SAY Press F1 for cheatsheet
F1 dacla.nfo
## GNU/Linux. Kernel versions are per Debian 10 oldstable.
LABEL dacla-0
LINUX /vmlinuz-4.19.0-20-amd64
INITRD /initrd.img-4.19.0-20-amd64
APPEND root=/dev/vgdacla-sys-i/lvroot-z62b588 ro cgroup_enable=memory i8042.nopnp
LABEL dacla-s0
COM32 cmd.c32
APPEND dacla-0 console=ttyS0
LABEL dacla-vga
COM32 cmd.c32
APPEND dacla-0 console=tty1 video=VGA-1:1280x1024-24
LABEL dacla-4.19.0-19-0
LINUX /vmlinuz-4.19.0-19-amd64
INITRD /initrd.img-4.19.0-19-amd64
APPEND root=/dev/vgdacla-sys-i/lvroot-z62b588 ro cgroup_enable=memory i8042.nopnp
## Dual-boot to NetBSD/9.2
LABEL dacla-nb
COM32 mboot.c32
APPEND /netbsd-9.2-generic.gz root=NAME=dacla-nb-root
## Dual-boot to FreeDOS
LABEL freedos
COM32 chain.c32
APPEND file=/kernl386.sys seg=0x60 nosect nohand
## Memtest86 and Memtest86+
LABEL memtest86
FDIMAGE /memtest86.bin
LABEL memtest86+
FDIMAGE /memtest86+.bin
### extlinux.conf ends here
Example "cheatsheet" (dacla.nfo) file is as follows.
Dacla. Linux 4.19.0 debian 20 amd64 (unsigned) [as of 2022-06-22]
Options:
debug= or break=PHASE (break=bottom) for when initramfs scripts fail;
init=/bin/bash for root password recovery, etc.
dacla-vga (default) has console=tty1 video=VGA-1:1280x1024-24 ;
dacla-s0 has console=ttyS0 ;
dacla-0 has neither;
dacla-4.19.0-19-0 uses an older kernel
(NB: add console= and video= as needed.)
dacla-nb add console=com (default: console=pc), -c, -s as needed.
Also available: freedos, memtest86, memtest86+.
--
FSF associate member #7257
http://am-1.org/~ivan/