Le 09/12/2021 à 00:25, Steve McIntyre a écrit :

Nod. A separate /usr filesystem is a configuration that was supported
well by d-i and Debian for a number of years, hence I agreed that it
was worth improving rescue-mode to explicitly support it. I *could*
also be convinced that we should do similar for a separate /var. Other
more exotic configurations are not as important IMHO:

  1. People configuring with *many* filesystems that they may want
     can run mount manually inside /target once things have started

  2. The main point of rescue mode (IMHO) is to get a system up and
     running *normally*, particularly if it doesn't boot
     currently. Hence the focus on /boot, boot/efi and now /usr. I
     believe we should not try to extend that list willy-nilly.

I mostly agree. Rescue mode serves two main purposes :
- Execute a shell in $RESCUE_ROOTDEV
- Reinstall the GRUB boot loader

As Philip pointed out, if splitting the hierarchy in some way breaks executing a shell in rescue mode, it seems fairly likely to break normal boot too. So IMO, the former does not need to mount more than what the initramfs does in order to run a usable shell (/, /dev, /proc, /run, /sys, /usr). Then people may mount whatever they need, for instance by running "mount -a".

However, the latter has more requirements.
- It executes grub-install which requires a separate /boot and /boot/efi to be mounted, and maybe /usr/share/grub. - Sometimes I create a separate /boot/grub filesystem when I want GRUB to be independent from the rest of the system. So you may consider mounting it too. - When the user chooses "Force GRUB installation to the EFI removable media path", 81grub-efi-force-removable executes debconf-set-selections. I guess this requires a separate /var to be mounted.

Cosmetic note about rescue-mode.templates : the two messages displayed before entering a shell contain "If you need any other file systems (such as a separate "/usr"), you will have to mount those yourself." Since /usr can now be mounted before executing the shell, shouldn't the messages be updated to change "/usr" to something else such as "/var" ?

Reply via email to