coreos / coreos/bootupd

Switching from RHEL 10 to Fedora 43 breaks boot loader due to missing grub.cfg

Open
#1,024 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
196
Forks
55
Avg merge
3d 2h
Merged PRs (30d)
14

Description

Copy the issue from bootc https://github.com/bootc-dev/bootc/issues/1734

When doing switches from RHEL 10 to Fedora 43, after reboot, check grub.cfg and bootuuid.cfg are in old vendor redhat, that will make the machine fails to boot a second time since grub.cfg cannot be found.

I think this is because bootupctl update only cares about EFI components like grub2 & shim, but do not update grub.cfg and bootuuid.cfg, although we have bootupctl adopt-and-update --with-static-config (PR#945), that will only update the 2 files in case ostree config --repo=/sysroot/ostree/repo get sysroot.bootloader is not set.

# mount /dev/nvme0n1p1 /boot/efi/
# ll -R /boot/efi/
/boot/efi/:
total 4
drwxr-xr-x. 5 root root 4096 Oct 17 13:14 EFI/

/boot/efi/EFI:
total 12
drwxr-xr-x. 2 root root 4096 Oct 17 13:14 BOOT/
drwxr-xr-x. 2 root root 4096 Oct 17 13:14 fedora/
drwxr-xr-x. 2 root root 4096 Oct 17 13:14 redhat/

/boot/efi/EFI/BOOT:
total 1016
-rwxr-xr-x. 1 root root 949424 Oct 17 13:14 BOOTX64.EFI
-rwxr-xr-x. 1 root root  87816 Oct 17 13:14 fbx64.efi

/boot/efi/EFI/fedora:
total 6644
-rwxr-xr-x. 1 root root     110 Oct 17 13:14 BOOTX64.CSV
-rwxr-xr-x. 1 root root 4046144 Oct 17 13:14 grubx64.efi
-rwxr-xr-x. 1 root root  848080 Oct 17 13:14 mmx64.efi
-rwxr-xr-x. 1 root root  949424 Oct 17 13:14 shim.efi
-rwxr-xr-x. 1 root root  949424 Oct 17 13:14 shimx64.efi

/boot/efi/EFI/redhat:
total 8
-rwxr-xr-x. 1 root root  53 Oct  7 19:15 bootuuid.cfg
-rwxr-xr-x. 1 root root 657 Oct  7 19:15 grub.cfg

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the bootupctl update and bootupctl adopt-and-update --with-static-config paths, then compare their handling of EFI components with grub.cfg and bootuuid.cfg. Reproduce the RHEL 10 to Fedora 43 switch and inspect whether the files remain under the old redhat vendor directory; done means the resulting boot configuration is updated and the machine boots again after a second reboot.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.