Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-86261

boot entry without initrd when GRUB_ENABLE_BLSCFG=false

Linking RHIVOS CVEs to...Migration: Automation ...SWIFT: POC ConversionSync from "Extern...XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done-Errata
    • Icon: Minor Minor
    • rhel-10.1
    • rhel-10.0
    • grub2
    • None
    • grub2-2.12-15.el10
    • Yes
    • Moderate
    • rhel-bootloader
    • ssg_core_services
    • 1
    • False
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • Unspecified
    • Unspecified
    • Unspecified
    • None

      What were you trying to do that didn't work?

      dnf upgrade kernel

      What is the impact of this issue to you?

      Host does not boot

      Please provide the package NVR for which the bug is seen:

      grub2-common.noarch                                    1:2.12-13.el10_0

      How reproducible is this bug?:

      systematically

      Steps to reproduce

       

      # cat /etc/default/grub
      GRUB_TIMEOUT=5
      GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
      GRUB_DEFAULT=saved
      GRUB_DISABLE_SUBMENU=true
      GRUB_TERMINAL_OUTPUT="console"
      GRUB_CMDLINE_LINUX="net.ifnames=0 biosdevname=0 crashkernel=2G-64G:256M,64G-:512M resume=UUID=bef768de-68c2-44e9-9a0f-a03b582aed8a rd.lvm.lv=rhel_win-dbausdhrjgi/root rd.lvm.lv=rhel_win-dbausdhrjgi/swap selinux=0 kasan_multi_shot net.ifnames=0 biosdevname=0 console=tty0 console=ttyS1,115200 audit=0"
      GRUB_DISABLE_RECOVERY="true"
      GRUB_ENABLE_BLSCFG=false

       

      Note that GRUB_ENABLE_BLSCFG=false is set.

      Install a kernel package, such as with `dnf upgrade kernel`.

      After installation, the new entry in /boot/grub2/grub.cfg is

      menuentry 'Red Hat Enterprise Linux (6.12.0-66.el10.x86_64) 10.0 (Coughlan)' --class red --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-6.12.0-66.el10.x86_64-advanced-89e583a6-4afa-40d4-ba80-418945b13032' {
              load_video
              insmod gzio
              insmod part_gpt
              insmod xfs
              set root='hd0,gpt2'
              if [ x$feature_platform_search_hint = xy ]; then
                search --no-floppy --fs-uuid --set=root --hint='hd0,gpt2'  6bf999ae-b5be-487a-bc81-f3e2c05e3559
              else
                search --no-floppy --fs-uuid --set=root 6bf999ae-b5be-487a-bc81-f3e2c05e3559
              fi
              echo    'Loading Linux 6.12.0-66.el10.x86_64 ...'
              linux   /vmlinuz-6.12.0-66.el10.x86_64 root=/dev/mapper/rhel_win--dbausdhrjgi-root ro net.ifnames=0 biosdevname=0 crashkernel=2G-64G:256M,64G-:512M resume=UUID=bef768de-68c2-44e9-9a0f-a03b582aed8a rd.lvm.lv=rhel_win-dbausdhrjgi/root rd.lvm.lv=rhel_win-dbausdhrjgi/swap selinux=0 kasan_multi_shot net.ifnames=0 biosdevname=0 console=tty0 console=ttyS1,115200 audit=0
      }

      Note that there is no "initrd" directive. As a result, the system does not boot.

      If I run

      # grub2-mkconfig -o /boot/grub2/grub.cfg
      Generating grub configuration file ...
      Found linux image: /boot/vmlinuz-6.12.0-66.el10.x86_64
      Found initrd image: /boot/initramfs-6.12.0-66.el10.x86_64.img
      Found linux image: /boot/vmlinuz-6.12.0-55.7.1.el10_0.x86_64
      Found initrd image: /boot/initramfs-6.12.0-55.7.1.el10_0.x86_64.img
      Found linux image: /boot/vmlinuz-0-rescue-ade619fd5f3141af81dee6b26c9b89a7
      Found initrd image: /boot/initramfs-0-rescue-ade619fd5f3141af81dee6b26c9b89a7.img
      Adding boot menu entry for UEFI Firmware Settings ...
      done

      The boot entry is updated to

      menuentry 'Red Hat Enterprise Linux (6.12.0-66.el10.x86_64) 10.0 (Coughlan)' --class red --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-6.12.0-66.el10.x86_64-advanced-89e583a6-4afa-40d4-ba80-418945b13032' {
              load_video
              insmod gzio
              insmod part_gpt
              insmod xfs
              set root='hd0,gpt2'
              if [ x$feature_platform_search_hint = xy ]; then
                search --no-floppy --fs-uuid --set=root --hint='hd0,gpt2'  6bf999ae-b5be-487a-bc81-f3e2c05e3559
              else
                search --no-floppy --fs-uuid --set=root 6bf999ae-b5be-487a-bc81-f3e2c05e3559
              fi
              echo    'Loading Linux 6.12.0-66.el10.x86_64 ...'
              linux   /vmlinuz-6.12.0-66.el10.x86_64 root=/dev/mapper/rhel_win--dbausdhrjgi-root ro net.ifnames=0 biosdevname=0 crashkernel=2G-64G:256M,64G-:512M resume=UUID=bef768de-68c2-44e9-9a0f-a03b582aed8a rd.lvm.lv=rhel_win-dbausdhrjgi/root rd.lvm.lv=rhel_win-dbausdhrjgi/swap selinux=0 kasan_multi_shot net.ifnames=0 biosdevname=0 console=tty0 console=ttyS1,115200 audit=0
              echo    'Loading initial ramdisk ...'
              initrd  /initramfs-6.12.0-66.el10.x86_64.img
      }

      and the system boots.

      This problem does not occur on RHEL-9.

      Looking at redhat/centos-stream/rpms/grub2.git, perhaps the following commit should be added to RHEL-10:

      d08fc02 Re-arm GRUB_ENABLE_BLSCFG=false

              bootloader-eng-team bootloader -eng-team
              rh-ee-bpoirier Benjamin Poirier
              bootloader -eng-team bootloader -eng-team
              Release Test Team Release Test Team
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: