When setting up a RAID-1 Ubuntu system (i.e. where /
and /boot
are on RAID-1 mirrors) it's unclear to me what Ubuntu's answer is to making the EFI System Partition (ESP, i.e. /boot/efi
) redundant, as well.
The Fedora solution, i.e. just putting it on a superblock 1.0 RAID-1, apparently isn't supported at all and thus makes grub-install
fail.
There seems to be some support for letting the Ubuntu installer create 2 ESPs and install the files to both of them. But according to this recent bug report it's still unclear how this scheme is supported by regular package updates:
https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1876974 (see also)
So how do I have to set up the ESP's on the both disks (when aiming for RAID-1 setup with - say - Ubuntu 20.04 LTS) to make them redundant and keep them in-sync for later Ubuntu updates?
The objective here is to still be able to boot that Ubuntu system, i.e. even when one disk dies.
How does my /etc/fstab
(or other relevant) configuration files have to look for such a setup?
For example, when the first ESP is mounted under /boot/efi
where has the second one to be mounted in order to be recognized by Ubuntu package post-install scripts?
And what are the necessary grub-install
/dpkg-reconfigure
/reinstall commands to fix the ESP setup after an installer failed to set up the ESPs correctly?
/boot
and/
are mirrored with mdadm or btrfs. With 1.0 Linux RAID superblocks the RAID doesn't have to be active during boot. The problem with your approach is that the second ESP isn't kept up-to-date when the grub package is updated. Or when any other package is updated that installs files into the ESP./boot/grub/grub.cfg
. The efi-compatible grub binaryefi\boot\bootx64.efi
orefi\distro\grubx64.efi
is only written once per system lifetime, usually.