Red Hat Bugzilla – Bug 1293725
UEFI bootloader is not updated by rpm-ostree, even though rpm package version suggests otherwise
Last modified: 2017-02-28 04:51:52 EST
Description of problem:
On a UEFI system, /boot/efi/EFI/fedora/grubx64.efi is not updated by 'rpm-ostree upgrade' even though the grub2-efi package version is updated.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. rpm-ostree upgrade
System is now on 23.38 and rpm -q reports grub2-efi-2.02-0.25.fc23.x86_64.
However, sha256sum of /boot/efi/EFI/fedora/grubx64.efi matches that of the grubx64.efi binary in grub2-efi-2.02-0.23.fc23.x86_64.rpm
grubx64.efi should be the binary in the package reported to be installed.
This is currently expected; there are no %post scripts per package on the client, they're all run on the compose server. extlinux used to update itself in %post but that was backed out.
Bootloaders for rpm-ostree are thus installed exactly once by Anaconda right now.
Offhand I'd say that it'd be best if Fedora had a once-per-major-version upgrade model for the bootloader. This could be a systemd service, or generally something shared by the fedup code and rpm-ostree.
Short term fix proposal: How about rpm -q spits back grub2-efi-2.02-0.23.fc23.x86_64.rpm? i.e. pin the version of the RPM so that it actually matches the version of the EFI bootloader binaries on the ESP? At least that way I'm not mislead by the reported version number into thinking I've got the 0.25 fix for CVE-2015-8370.
I don't think it's realistic to have a once per major version upgrade model. The updates aren't arbitrary, they happen when they happen, and we have to have a way for atomic baremetal installs to be as secure and up to date as non-atomic baremetal installs - eventually.
For example, grub2-2.02-0.7.fc22 is the first instance of GRUB for Fedora 22, and the current one is grub2-2.02-0.18.fc22. In that time frame, CVE-2014-4607 and CVE-2015-8370 were fixed, as were a bunch of bugs. On average it looks like each release sees GRUB updated about 10 times.
I see this bug as a kind of regression from UEFI non-atomic installs, back to the broken state on BIOS, except worse because grub2-install isn't available on UEFI. The user has to know to copy /usr/lib/ostree-boot/efi/EFI/fedora/grubx64.efi to the ESP to actually update the bootloader.
I agree this is a problem that we need to fix, but it's also not new to Atomic; *non*-UEFI *non* Atomic, i.e. BIOS "mainline" installs also don't have the bootloader updated by RPM updates either.
Unlikely to design a solution here soon, but keeping the bug open.
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora 'version'
Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.
Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 23 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.
Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.
This bug appears to have been reported against 'rawhide' during the Fedora 26 development cycle.
Changing version to '26'.