On 10/28/22 11:31, Jake D wrote:
I’ve managed to chroot (a very dumb word) thru a LiveUSB session, with the 
following commands:

It's better not to call things dumb without understanding. It's short for CHange ROOT, which does what it says.

cryptsetup luksOpen /dev/nvme0n1p6 fedora_crypt
mount /dev/mapper/fedora_crypt /mnt/ -t btrfs -o subvol=root
mount /dev/mapper/fedora_crypt /mnt/home -t btrfs -o subvol=home
mount /dev/nvme0n1p5 /mnt/boot
mkdir /mnt/boot/efi
mount /dev/nvme0n1p1 /mnt/boot/efi
mount --bind /dev /mnt/dev
mount -t proc /proc /mnt/proc
mount -t sysfs /sys /mnt/sys
mount -t tmpfs tmpfs /mnt/run
mkdir -p /mnt/run/systemd/resolve/
nano /mnt/run/systemd/resolve/stub-resolv.conf (enter 'nameserver 1.1.1.1', 
save)
chroot /mnt

dnf reinstall grub2-efi grub2-efi-modules shim

That seems to work? Downloads and seems to install without any errors.

The next step though;

grub2-mkconfig -o /boot/grub2/grub.cfg

fails with the following:

/usr/sbin/grub2-probe: error: failed to get canonical path of 
‘/dev/mapper/fedora_crypt’
I have no idea what that means.

What does "ls -l /dev/mapper/fedora_crypt" show?

On the side, I also sees that despite the grub reinstall, theres no vmlinuz or 
initramfs kernel files in the reconstructed /boot partition, so I tried running

grub has nothing directly to do with those files.

dracut --regenerate-all

which results in

dracut: Can’t write to /boot/efi/[long-ass id code string]/[kernel version]: 
Directory /boot/efi/[long-ass id code string]/[kernel version] does not exist 
or is not accessible.

This is true - that folder isn’t in /boot/efi. But I dont remember ever seeing 
it there, and just to check I did a fresh test install on another drive and 
theres nothing like that there either.

That's one of the possible places for it to write the files. Did it find the right place? If not, you'll have to specify the file yourself.
"rpm -q kernel-core"
e.g. kernel-core-5.18.13-200.fc36.x86_64
"dracut /boot/initramfs-5.18.13-200.fc36.x86_64.img 5.18.13-200.fc36.x86_64"
You will also have to re-install the kernel-core package to the vmlinuz file installed.

At this point, it might just be easier to do a backup and re-install.
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue

Reply via email to