All started when I wanted to change GRUB boot order and installed grub-customizer, what was fatal mistake- after this I had only Windows and UEFI listed in GRUB after reboot.
I found a few tutorials how to handle that (I’m using live USB with Fedora 36 now) and what I was trying to do same as here:
The problem is, when I’m trying to execute grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg I’m getting “/usr/sbin/grub2-probe: error: cannot find a device for / (is /dev mounted?).”
I found some trick to mount again in chroot mode the root partition as “/” (grub2 - Trying to reinstall GRUB 2, cannot find a device for /boot (is /dev mounted?) - Ask Ubuntu) so mount /dev/sdaX / and looks like it helps, however it generates another error when trying to grub2-mkconfig: “sed: can’t read /etc/system-release: No such file or directory” - the case is, this file is really there lol, but it’s empty inside, I’m not sure if it’s correct.
First you will need to properly mount the installed system while booted to the live USB. These instructions assume your install is using btrfs with the default config on a clean f36 install, so may need to be altered if you have done something different.
become root su
run fdisk -l and lsblk to obtain all the needed partition info to continue.
You will need the UUID for the root partition as well as the device names or UUIDs for /boot and /boot/efi
from the info found in step 1, mount the / partition of your install at /mnt sudo mount -t btrfs -o subvol=root,compress=zstd:1 UUID=<your OS UUID here> /mnt
mount your /boot partition at at /mnt/boot
mount your efi (esp) partition at /mnt/boot/efi
mount the other needed partitions sudo for i in sys proc dev run ; do mount -t bind /$i /mnt/$i ; done
Thank you Jeff, your solution worked, I have twice Windows Boot Manager and UEFI config on the list but it’s not a problem, when booting to Fedora it loads quite long in console mode and suspends at this step:
I was able then to log into when using older snapshot but strange thing happened, resolution is very small and can’t be changed plus something else I can’t remember. I tried to run some updates and reboot but I stuck again on the step from the picture. I think I have to run full reinstall
Strange it happened only due to some GRUB issue :?