I have multiple encrypted OSes booting from the EOS grub.
I installed each OS on a single encypted LUKS partition, manually configured with a swapfile post install.
Some non Arch based distros may require separate EFI, /boot and root partitions on encrypted installs (ie Fedora). Change as necessary.
I manually partition first using gparted, EFI + root partition, then install into the root partition. All other personal data is kept on separate encrypted disks.
NAME
sdb
├─sdb1 300M FAT32
├─sdb2 50G LUKS
├─sdb3 300M FAT32
├─sdb4 50G LUKS
├─sdb5 300M FAT32
├─sdb6 50G LUKS
├─sdb7 300M FAT32
├─sdb8 50G LUKS
sdb2 has EOS, sdb4 has vanilla Arch, sdb6 has Artix, sdb8 has Debian 10.5 (but this changes frequently, Fedora 33 next ).
I installed EOS, Artix and Debian using the Calamares option to replace existing installation, chose the correct root partiton, and selected encrypt install with no swap partition. Add swapfile post install.
The Arch install was done manually.
After completing all the installs ensure EOS is first in the boot order using efibootmgr -o
, or configure boot order in BIOS settings. Or just install EOS last.
When a new distro is installed, or when grub is re-installed in any distro (manually or automatically)
sudo grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=[Distro-Label] --recheck
Re-check the boot order to ensure EOS boots first.
To boot other encrypted distros EOS grub you cannot rely on os-prober
to find them and add automatically. She don’t. You’ll have to add them manually.
For the sake of simplicity I chainload grubs instead of manually creating bootable grub entries, which is a PITA with crypto related setup (see your /boot/grub/grub.cfg for details).
These entries are added into /etc/grub.d/40_custom
.
/etc/grub.d/40_custom
#!/bin/sh
exec tail -n +3 $0
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
menuentry "Arch" {
set root="hd1,gpt3"
chainloader /EFI/Arch/grubx64.efi
}
menuentry "Artix" {
set root="hd1,gpt5"
chainloader /EFI/Artix/grubx64.efi
}
submenu "Other" {
menuentry "Debian" {
set root="hd1,gpt7"
chainloader /EFI/Debian/grubx64.efi
}
menuentry "EndeavourOS Rescue" {
set root="hdX,gptY"
chainloader /EFI/EndeavourOS2/grubx64.efi
}
}
Root is the efi partition, chainloader is the path to the grub efi stub. HdX is a zero based disk number, gptY is non zero based partition number.
Each entry in 40_custom
wll have an EOS grub menu item, selecting will launch grub for the particular OS. Proceed as usual.
Off Topic
I do all my backup / restore / possible chroot fixes from a rescue system rather than live ISO. All the tools I need are installed and configured to my liking. The rescue system was not installed, but a clone of EOS root partition using rsync and tweaked to boot. Not really relevant for this topic though.