if I migrate a bookworm installation from grub-pc to grub-uefi,
then grub-pc.postrm removes /etc/default/grub on the final purge.
AFAICT /etc/default/grub is still processed for UEFI, so why
is it deleted?
It is a known bug.
On 2024-05-24 20:36:41, Pascal Hambourg wrote:
It is a known bug.
This is a highly destructive bug. You have UEFI boot finally working,
you just do some cleanup, and on the next reboot of your server 8
weeks later it doesn't boot anymore. :-(
AFAICT the problem is the config file isn't properly managed by *any* package:
# dpkg -S /etc/default/grub
dpkg-query: no path found matching pattern /etc/default/grub
Doesn't this violate some Debian policy manual? I remember something
about not unconditionally overwriting config files.
This is a highly destructive bug. You have UEFI boot finally working,
you just do some cleanup, and on the next reboot of your server 8
weeks later it doesn't boot anymore. :-(
- Remove /etc/default/grub only if it is associated with the package
being purged in ucf.
- Do not remove /etc/default/grub when purging package-<target>
because
it is used by grub-install and update-grub which belong to grub2-
common;
only remove it from ucf registry if it is associated with the package
being purged.
Also, it appears that grub-pc.postrm purge optionally removes files
in
/boot/grub which may have been installed for other grub targets
(grub.cfg, fonts, locales, device.map, grubenv, background image
cache).
My opinion is that postrm should not touch /boot/grub at all. After
all,
it does not remove GRUB boot image and core image nor EFI partition contents.
Grub-team people, any comments ?
d-boot is actually the wrong mailing list to discuss grub.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 486 |
Nodes: | 16 (2 / 14) |
Uptime: | 134:29:54 |
Calls: | 9,657 |
Calls today: | 5 |
Files: | 13,707 |
Messages: | 6,166,830 |