Bug#1135137: upgrade-reports: Bookworm -> Trixie mdadm raid EFI not updated on both disks

Pascal Hambourg pascal at plouf.fr.eu.org
Wed Apr 29 23:46:30 BST 2026


Thorsten Behrens wrote:
> 
> On a fresh install of Debian 12, on an OVH baremetal machine with mdadm
> raid-0, I upgraded to Debian 13. After upgrade, grub in EFI had been
> upgraded in one drive, but not the other.

What is the point of having multiple ESPs with RAID 0 ? It does not 
provide any redundancy, so if either drive fails the system would fail 
to boot anyway.

> I can reproduce this, and the drive that does get upgraded appears to be
> somewhat random.

Both ESPs have the same LABEL (this is wrong, LABELs should be unique) 
and fstab mounts the ESP by LABEL. So the mounted ESP is chosen randomly 
(or at least not reliably) and only the ESP mounted on /boot/efi is 
updated by grub-install.

> $ strings /boot/efi/EFI/debian/grubx64.efi | grep -i grub | tail -6
> grub,4,Free Software Foundation,grub,2.06,https://www.gnu.org/software/grub/
> grub.debian,4,Debian,grub2,2.06-13+deb12u1,https://tracker.debian.org/pkg/grub2

FWIW this is the contents of the embedded SBAT CSV, not the GRUB 
version. The actual GRUB version can be found in another string:

GNU GRUB  version %s
2.06-13+deb12u1

> Completely amazing ofc would be that grub-install or "whatever
> responsible component" sees all EFI entries in efibootmgr and upgrades /
> installs into all of them

EFI boot entries are not reliable enough. They do not even exist on some 
systems.

> A thought on how to improve the postinst of grub
> Something along these lines - not this exact script, but in spirit - would update grub on all ESPs

This is a bad idea. Not all detected ESPs may belong to this system.
A correct solution requires to record the ESPs which are managed by this 
system and must be updated.



More information about the Pkg-grub-devel mailing list