[TRACKING] PSA: Possible Fedora bug: after updating kernel, system still defaults to booting old kernel

This has persisted in cropping up and complicating troubleshooting of various other problems so I thought it’s worth more visibiliy:

Fedora 39, at least when fresh installed, somehow is set up so that when the kernel is updated, the option to make the just-installed kernel version the default on boot is not enabled. This is the opposite of default Fedora behavior from as far back as I can remember (decade or so).

It’s been covered in various “adjacent” threads here. The summary to fix this is that:

  • If it doesn’t exist, create (as root) the file /etc/sysconfig/kernel.

  • In that file, these two options should be set as:

    # UPDATEDEFAULT specifies if new-kernel-pkg should make
    # new kernels the default
    UPDATEDEFAULT=yes
    
    # DEFAULTKERNEL specifies the default kernel package type
    DEFAULTKERNEL=kernel-core
    

    (credit to @jwp for pointing this out)

  • If you’ve already installed the kernel version you want made default, either of these steps should complete the fix (using 6.6.10 currently in the testing “channel”):

    • sudo dnf reinstall kernel-core-6.6.10 in a terminal.

    or

    • Reboot.

    • When the Framework logo appears, press Esc every few seconds. The grub menu should appear.

      • If you pressed Esc one time too many, you’re in the grub shell, just ctrl-alt-del to try again (instructions for a better way welcome).
    • Select the (latest) kernel you want to boot into.

  • Once you’ve rebooted the “kernel update makes new version the default” should be the behavior going forward.

(Aside, and separate discussion really: I want to reproduce this in a VM and open a bug on the Redhat Bugzilla but somehow I can’t create a new VM.)

1 Like

I am experiencing no issues with this, and the only time I have in the past is when I have explicitly changed it and forgotten about it. This looks less like a bug and more like a result of running on the testing “channel”.

I also cannot replicate it using the default install media in either a VM or on bare metal. If it cannot be replicated there is not much that can be done.

that was just the latest kernel, installed while it was still in updates-testing, before it got promoted to stable (which wouldn’t have made a difference as far as this issue goes). The behavior had been consistent for me (and several others in the forum) at least a while ago.

It could well be then that this was fixed, does the install ISO (specifically, live Workstation) itself get periodically updated? FWIW I did this fresh install just days after F39 went GA in November.

Anyway, if it’s no longer reproducible that’s good, it is/was interfering with other troubleshooting.

1 Like

Tracking this as it appears to have affected a few folks. I also have not been able to replicate as of yet. Multiple fresh installs.

Any chance folks are coming from an older release to Fedora 39 and seeing this issue?

Yeah, I have no idea why this isn’t consistent. I was theorizing earlier (see above) that the installer within the ISO itself (anaconda?) had been updated in a subsequent version of the ISO.

However from what I can see opening https://download.fedoraproject.org/pub/fedora/linux/releases/39/Workstation/x86_64/iso/, any mirror I get only has the November 1st image.

I went with defaults during installation, only “option” was selecting LUKS.

What else… grubby invocations during the early days to add the amdgpu and ACPI alarm kernel args - somehow those messed up the default? Shouldn’t happen…