2 out of our 31 lab computers that were upgraded from Fedora 29 to Fedora 30 are showing kernel’s in use from Fedora 29. cat /etc/redhat-release Fedora release 30 (Thirty)
then: uname -a Linux ourhost.edu 4.19.12-301.fc29.x86_64 #1 SMP Mon Dec 24 01:58:57 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
However there does appear to be a F30 kernel: rpm -q kernel kernel-5.0.17-200.fc29.x86_64 kernel-4.19.12-301.fc29.x86_64 kernel-5.0.17-300.fc30.x86_64
Just to be sure, from advice from an older thread, I ran: dnf reinstall shim grub2-efi kernel kernel-* grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg
I rebooted and the same happens. Here are the boot options I see:
You can see these are dual-boot machines with Windows 10. I also ran dnf distro-sync --allowerasing to no avail.
Either you just didn’t actually reinstall the packages or your computer is generating entries in the wrong format.
The package names are shim-x64 (or shim-ia32) and grub2-efi-x64 (or grub2-efi-ia32). Just run dnf reinstall shim* grub* kernel* (I’ll explain why I say “grub*” in a second)
This doesn’t look like a blscfg (fedora’s new bootloader configuration) configuration (yours says “Workstation Edition,” mine says “Thirty”). The issue is that (to my knowledge) grubby, which generates entries for new kernels, now only generates entries in blscfg format, where the “grubby-deprecated” provides the old functionality. What I don’t get is why grub2-mkconfig didn’t work. Perhaps that’s because the package wasn’t actually reinstalled.
OK I reinstalled them all. Re-ran the grub2mkconfig, still getting: uname -a Linux ouserver.edu 4.19.12-301.fc29.x86_64 #1 SMP Mon Dec 24 01:58:57 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
cat /boot/efi/EFI/fedora/grub.cfg
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub2-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#
### BEGIN /etc/grub.d/00_header ###
set pager=1
if [ -f ${config_directory}/grubenv ]; then
load_env -f ${config_directory}/grubenv
elif [ -s $prefix/grubenv ]; then
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="${saved_entry}"
fi
if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi
export menuentry_id_option
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}
terminal_output console
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=menu
set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
set timeout=5
fi
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/01_users ###
if [ -f ${prefix}/user.cfg ]; then
source ${prefix}/user.cfg
if [ -n "${GRUB2_PASSWORD}" ]; then
set superusers="root"
export superusers
password_pbkdf2 root ${GRUB2_PASSWORD}
fi
fi
### END /etc/grub.d/01_users ###
### BEGIN /etc/grub.d/08_fallback_counting ###
insmod increment
# Check if boot_counter exists and boot_success=0 to activate this behaviour.
if [ -n "${boot_counter}" -a "${boot_success}" = "0" ]; then
# if countdown has ended, choose to boot rollback deployment,
# i.e. default=1 on OSTree-based systems.
if [ "${boot_counter}" = "0" -o "${boot_counter}" = "-1" ]; then
set default=1
set boot_counter=-1
# otherwise decrement boot_counter
else
decrement boot_counter
fi
save_env boot_counter
fi
### END /etc/grub.d/08_fallback_counting ###
### BEGIN /etc/grub.d/10_linux ###
insmod part_gpt
insmod lvm
insmod ext2
set root='lvmid/HXUIBG-pPSc-vbGa-2pQ8-meYd-TOPD-A2YFDQ/ztrNsZ-2NyP-tJxj-fXVA-Fiw5-Sq2z-Iq107z'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint='lvmid/HXUIBG-pPSc-vbGa-2pQ8-meYd-TOPD-A2YFDQ/ztrNsZ-2NyP-tJxj-fXVA-Fiw5-Sq2z-Iq107z' 664c3c0d-5c50-4817-946e-adca82e47eb4
else
search --no-floppy --fs-uuid --set=root 664c3c0d-5c50-4817-946e-adca82e47eb4
fi
insmod part_gpt
insmod lvm
insmod ext2
set boot='lvmid/HXUIBG-pPSc-vbGa-2pQ8-meYd-TOPD-A2YFDQ/ztrNsZ-2NyP-tJxj-fXVA-Fiw5-Sq2z-Iq107z'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=boot --hint='lvmid/HXUIBG-pPSc-vbGa-2pQ8-meYd-TOPD-A2YFDQ/ztrNsZ-2NyP-tJxj-fXVA-Fiw5-Sq2z-Iq107z' 664c3c0d-5c50-4817-946e-adca82e47eb4
else
search --no-floppy --fs-uuid --set=boot 664c3c0d-5c50-4817-946e-adca82e47eb4
fi
# This section was generated by a script. Do not modify the generated file - all changes
# will be lost the next time file is regenerated. Instead edit the BootLoaderSpec files.
#
# The blscfg command parses the BootLoaderSpec files stored in /boot/loader/entries and
# populates the boot menu. Please refer to the Boot Loader Specification documentation
# for the files format: https://www.freedesktop.org/wiki/Specifications/BootLoaderSpec/.
set default_kernelopts="root=/dev/mapper/lvm2-root ro rd.lvm.lv=lvm2/root rd.lvm.lv=lvm2/swap rhgb quiet "
insmod blscfg
blscfg
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/10_reset_boot_success ###
insmod increment
# Hiding the menu is ok if last boot was ok or if this is a first boot attempt to boot the entry
if [ "${boot_success}" = "1" -o "${boot_indeterminate}" = "1" ]; then
set menu_hide_ok=1
else
set menu_hide_ok=0
fi
# Reset boot_indeterminate after a successful boot, increment otherwise
if [ "${boot_success}" = "1" ] ; then
set boot_indeterminate=0
else
increment boot_indeterminate
fi
# Reset boot_success for current boot
set boot_success=0
save_env boot_success boot_indeterminate
### END /etc/grub.d/10_reset_boot_success ###
### BEGIN /etc/grub.d/12_menu_auto_hide ###
if [ x$feature_timeout_style = xy ] ; then
if [ "${menu_show_once}" ]; then
unset menu_show_once
save_env menu_show_once
set timeout_style=menu
set timeout=60
elif [ "${menu_auto_hide}" -a "${menu_hide_ok}" = "1" ]; then
set orig_timeout_style=${timeout_style}
set orig_timeout=${timeout}
if [ "${fastboot}" = "1" ]; then
# timeout_style=menu + timeout=0 avoids the countdown code keypress check
set timeout_style=menu
set timeout=0
else
set timeout_style=hidden
set timeout=1
fi
fi
fi
### END /etc/grub.d/12_menu_auto_hide ###
### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/20_ppc_terminfo ###
### END /etc/grub.d/20_ppc_terminfo ###
### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Windows Boot Manager (on /dev/sda1)' --class windows --class os $menuentry_id_option 'osprober-efi-3C49-68B0' {
insmod part_gpt
insmod fat
set root='hd0,gpt1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt1 --hint-efi=hd0,gpt1 --hint-baremetal=ahci0,gpt1 3C49-68B0
else
search --no-floppy --fs-uuid --set=root 3C49-68B0
fi
chainloader /EFI/Microsoft/Boot/BootMgFW.efi
}
# Other OS found, undo autohiding of menu unless menu_auto_hide=2
if [ "${orig_timeout_style}" -a "${menu_auto_hide}" != "2" ]; then
set timeout_style=${orig_timeout_style}
set timeout=${orig_timeout}
fi
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/30_uefi-firmware ###
menuentry 'System setup' $menuentry_id_option 'uefi-firmware' {
fwsetup
}
### END /etc/grub.d/30_uefi-firmware ###
### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
### BEGIN /etc/grub.d/41_custom ###
if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
@RobbieTheK, @benjamind, I’ve checked posted grub.cfg, compared it to mine. It looks like (just from looking at the files, without reading docs) with latest changes with blscfg in F30 we should actually check the contents of /boot/loader/entries/ folder.
In the grub.cfg itself only this section now refers to all Fedora’s boot entries:
The entries themselves are taken by blscfg from /boot/loader/entries/ (check the comment in grub.cfg immediately above the lines I quoted).
So regenerating grub.cfg itself won’t change anything, we need to properly regenerate blscfg entries. Presumably new grubby @benjamind mentioned should do it, not grub2-mkconfig. I’ll try to look into it and post here if I find anything. blscfg is all new for me too
Edit 1: The entries files themselves are human-readable and easy to understand, I’m quite sure we can easily add new boot entry by copying existing file and modifying it to point to the kernel we need (assuming said kernel is actually installed).
Edit 2: To add new already installed kernel to /boot/loader/entries/ you can use the following command:
If these are EFI bios machines, then you should be able to run bootctl to simply get a status of your bootloader efi entries. It can also be used to manipulate the bootloader through systemd-boot. Follow this link if you want to check it out further… https://www.freedesktop.org/software/systemd/man/bootctl.html or use the man page for it with man bootctl. With the new BLS being followed, there should be less pain in setting up multi-boot systems, especially efi ones but generally across the spectrum.
@RobbieTheK, as you can see in output of grubby --info ALL, there’s an entry for F30 kernel 5.0.17-300.fc30.x86_64. Do you actually see it upon booting?
Can you repost screenshot of grub menu upon boot (previous one should have changed by now).
Perhaps this will help. Looks like there is a difference between workstations that did upgrade to F30 and ones that didn’t/. Here’s the “bad” one:
bootctl
Couldn’t find EFI system partition. It is recommended to mount it to /boot or /efi.
Alternatively, use --path= to specify path to mount point.
System:
Firmware: n/a (n/a)
Secure Boot: disabled
Setup Mode: user
Current Boot Loader:
Product: n/a
Features: ✗ Boot counting
✗ Menu timeout control
✗ One-shot menu timeout control
✗ Default entry control
✗ One-shot entry control
ESP: n/a
File: └─n/a
Boot Loaders Listed in EFI Variables:
Title: rEFInd
ID: 0x0001
Status: active, boot-order
Partition: /dev/disk/by-partuuid/614009be-acab-46ee-a89a-a82eae70bb4b
File: └─/EFI/refind/refind_x64.efi
Title: UEFI: HGST HTS721010A9E630
ID: 0x0002
Status: active, boot-order
Partition: /dev/disk/by-partuuid/614009be-acab-46ee-a89a-a82eae70bb4b
File: └─EFI/boot/bootx64.efi
Title: Choose Your Operating System
ID: 0x0000
Status: active, boot-order
Partition: /dev/disk/by-partuuid/b10e02a2-0931-4a6d-b108-2791a30efe4d
File: └─/EFI/fedora/grubx64.efi
Here’s the “good” one: bootctl status systemd-boot not installed in ESP. System: Firmware: n/a (n/a) Secure Boot: disabled Setup Mode: user
Current Boot Loader:
Product: n/a
Features: ✗ Boot counting
✗ Menu timeout control
✗ One-shot menu timeout control
✗ Default entry control
✗ One-shot entry control
ESP: n/a
File: └─n/a
Available Boot Loaders on ESP:
ESP: /boot/efi (/dev/disk/by-partuuid/614009be-acab-46ee-a89a-a82eae70bb4b)
File: └─/EFI/BOOT/BOOTIA32.EFI
File: └─/EFI/BOOT/BOOTX64.EFI
Boot Loaders Listed in EFI Variables:
Title: rEFInd Boot Manager
ID: 0x0001
Status: active, boot-order
Partition: /dev/disk/by-partuuid/614009be-acab-46ee-a89a-a82eae70bb4b
File: └─/EFI/refind/refind_x64.efi
Title: Choose Desired Operating System
ID: 0x0000
Status: active, boot-order
Partition: /dev/disk/by-partuuid/b10e02a2-0931-4a6d-b108-2791a30efe4d
File: └─/EFI/refind/refind_x64.efi
Title: UEFI: HGST HTS721010A9E630
ID: 0x0002
Status: active, boot-order
Partition: /dev/disk/by-partuuid/614009be-acab-46ee-a89a-a82eae70bb4b
File: └─EFI/boot/bootx64.efi
0 entries, no entry could be determined as default.
AFAIK Grub2 is no longer the actual Grub2 package but a series of scripts that use bootctl and systemd-boot to manipulate things, and most of the manipulated files are human readable text so configuration should be less painful. Emphasis on should.
I think they may be older MBR, so BIOS machines not EFI. Then you will need to use the grubby tool to manipulate things a bit. For instance it can create a new entry based upon a current working one, so the F29 bootable entries can be used as a starting point to create an entry for the F30 kernels and initramfs.
So take a look at grubby --copy-default for a start, this would copy your default kernel entry (presumably F29 in this case) and make a new entry without the kernel or initrd files that you would modify to suit whatever kernel and initrd files you wanted to boot into. I think there is also a grub2 command for BLS conversion too, I’ll do some digging into that later or you can search it.
AFAIK, Secure Boot shouldn’t interfere here, I’ve used Fedora with it enabled. I’d verify that grub is using that same grub.cfg file you’ve posted and not some other. That’s why I asked for a new screenshot
You have two EFI partitions, look at sda1 and sda7. That’s not good, as far as I know it should be only one. This can confuse at least some utitities/bootloaders, if not all.
Have to go now, will look closer from home. I’d say you change grub.cfg on one partition (sda7), but then boot from another (sda1) – and that’s the root of your problem. But let’s look more closely at the output first.
Yes when we created these, we didn’t realize that we could just use one partition for both Windows and Fedora. Keep in mind 28 other computers updated perfectly.