Unable to Boot From Encrypted /boot on mdadm luks lvm

Ask for help with issues regarding the Installations of the Debian O/S.
Post Reply
Message
Author
vrtsun
Posts: 3
Joined: 2024-07-29 00:41

Unable to Boot From Encrypted /boot on mdadm luks lvm

#1 Post by vrtsun »

After doing a test Debian install in a vm from the standard installer with mdadm raid1 > luks > lvm, booting into it, and converting it have encrypted boot with the following commands

Code: Select all

cp -axT /boot /boot2
umount -R /boot
rm -r /boot
mv /boot2 /boot
mount /boot/efi
#remove /boot from fstab
cryptsetup luksConvertKey --pbkdf pbkdf2 /dev/md0
echo "GRUB_ENABLE_CRYPTODISK=y" >> /etc/default/grub
update-grub
grub-install /boot/efi
and rebooting, the system drops me to the grub shell. Those same commands worked on a test install on a single disk that didn't use mdraid. I'm also able to create a system with mdraid luks lvm on opensuse tumbleweed from the installer and it boots fine. Here's fstab, blkid, lvm lvdisplay, grub config on /boot/efi, and grub config on /boot/grub from each system.
mdraid luks lvm debian (not bootable) https://paste.debian.net/1324676/ luks lvm debian (bootable) https://paste.debian.net/1324677/ mdraid luks lvm opensuse (bootable) https://paste.debian.net/1324678/

Is this something wrong with what I did or a bug in grub or something else?

Thanks!

werta
Posts: 6
Joined: 2024-08-06 09:36
Been thanked: 2 times

Re: Unable to Boot From Encrypted /boot on mdadm luks lvm

#2 Post by werta »

Make sure GRUB_ENABLE_CRYPTODISK=y is set and update-grub has been run. You can also regenerate the initramfs to include necessary encryption and RAID modules, and check that UUIDs and crypttab entries are accurate.
Have a great day ;)

Post Reply