eccerr0r Watchman
Joined: 01 Jul 2004 Posts: 9824 Location: almost Mile High in the USA
|
Posted: Mon Apr 29, 2024 3:45 pm Post subject: grub-probe can't figure cryptsetup and dies [solved] |
|
|
Not sure what people are doing for this use case:
I just set up a machine with FDE using initramfs that sets up my LUKS rootfs. Before actually doing the encryption I tried getting a unencrypted image working first (well, I *had* the image since it was pulled from another machine.)
However now with the LUKS rootfs,
Code: | localhost /boot/grub # grub-mkconfig
/usr/sbin/grub-probe: error: failed to get canonical path of `/dev/mapper/rootfs'. |
Well, true that it probably has no hope figuring out what my initramfs does, but could it be possible to get grub-probe and grub-mkconfig to just return root=/dev/mapper/rootfs even if it has no chance of fully assembling the cryptroot (or better yet my rootfs on RAID5 on cryptfs)? I have /etc/default/grub doing most of the work on setting my initramfs up, but if it gives up and dies, I don't even get a grub.cfg skeleton that I could hand hack to work.
I recall this working "properly" at one point, but this is now grub-2.12 ...
Hmm. New clue: might be something wrong with accounting
Code: | # lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 238.5G 0 disk
├─sda1 8:1 0 128M 0 part /boot
└─sda2 8:2 0 238.3G 0 part
sr0 11:0 1 1024M 0 rom |
I thought that lsblk would notice my luks container is based off of /dev/sda2 but now isn't showing it for some reason, or maybe I was delusional at some point lsblk knew. It definitely keeps track of RAID partitions but ...did luks qualify? Weird thought it did...
SOLVED
I think it's because of the order of events. What i needed to do was get device mapper to rebuild by running dmsetup mknodes -- and now the previous behavior works as it should. _________________ Intel Core i7 2700K/Radeon R7 250/24GB DDR3/256GB SSD
What am I supposed watching? |
|