Bug 1785460

Summary: blscfg does not copy grubenv's kernel opts to $kernelopts
Product: Red Hat Enterprise Linux 8 Reporter: lidokawaiibear
Component: grub2Assignee: Bootloader engineering team <bootloader-eng-team>
Status: CLOSED WORKSFORME QA Contact: Release Test Team <release-test-team-automation>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 8.0CC: fmartine
Target Milestone: rc   
Target Release: 8.0   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-07-17 08:34:34 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
boot loader specification configuration
none
grubenv none

Description lidokawaiibear 2019-12-19 22:23:46 UTC
Description of problem:
After install new kernel via yum, kernel does not boot with blscfg because kernelopts appears to be empty.

In /boot/loader/entries/*kernel.conf: 
options $kernelopts $tuned_params
In /boot/grub2/grubenv:
kernelopts=UUID=(uuid) console=tty0 crashkernel=auto console=ttyS0,115200 ro

When booting, none of these kernel options appear, only listed is linux vmlinuz*


Version-Release number of selected component (if applicable):


How reproducible:
Every time


Steps to Reproduce:
1. yum install kernel-debug
2. reboot

Actual results:
Boots into emergency shell due to no kernel options

Expected results:
Boots into new kernel


Additional info:
If I manually copy kernelopts from grubenv to /boot/loader/entries' kernelopts, it boots as expected

Comment 1 Javier Martinez Canillas 2019-12-19 23:31:21 UTC
(In reply to lidokawaiibear from comment #0)
> Description of problem:
> After install new kernel via yum, kernel does not boot with blscfg because
> kernelopts appears to be empty.
> 
> In /boot/loader/entries/*kernel.conf: 
> options $kernelopts $tuned_params
> In /boot/grub2/grubenv:
> kernelopts=UUID=(uuid) console=tty0 crashkernel=auto console=ttyS0,115200 ro
> 
> When booting, none of these kernel options appear, only listed is linux
> vmlinuz*
> 

What's your grub2 package version?

Also, can you please share your /boot/grub2/grubenv and the BLS files in /boot/loader/entries ?

Comment 2 lidokawaiibear 2019-12-19 23:38:59 UTC
(In reply to Javier Martinez Canillas from comment #1)
> (In reply to lidokawaiibear from comment #0)
> > Description of problem:
> > After install new kernel via yum, kernel does not boot with blscfg because
> > kernelopts appears to be empty.
> > 
> > In /boot/loader/entries/*kernel.conf: 
> > options $kernelopts $tuned_params
> > In /boot/grub2/grubenv:
> > kernelopts=UUID=(uuid) console=tty0 crashkernel=auto console=ttyS0,115200 ro
> > 
> > When booting, none of these kernel options appear, only listed is linux
> > vmlinuz*
> > 
> 
> What's your grub2 package version?
> 
> Also, can you please share your /boot/grub2/grubenv and the BLS files in
> /boot/loader/entries ?

My grub2 is v2.03.

grubenv:
# GRUB Environment Block
saved_entry=0
kernelopts=root=UUID=7b13b9d6-cd21-44a4-aea6-05400b8410ac ro console=tty0 rd_NO_PLYMOUTH crashkernel=auto console=ttyS0,115200
#####

entry configuration:
title CentOS Linux (4.18.0-80.el8.x86_64) 8 (Core)
version 4.18.0-80.el8.x86_64
linux /vmlinuz-4.18.0-80.el8.x86_64
initrd /initramfs-4.18.0-80.el8.x86_64.img $tuned_initrd
options $kernelopts $tuned_params
id centos-20190604092737-4.18.0-80.el8.x86_64
grub_users $grub_users
grub_arg --unrestricted
grub_class kernel

Comment 3 Javier Martinez Canillas 2019-12-19 23:55:44 UTC
(In reply to lidokawaiibear from comment #2)
> (In reply to Javier Martinez Canillas from comment #1)
> > (In reply to lidokawaiibear from comment #0)
> > > Description of problem:
> > > After install new kernel via yum, kernel does not boot with blscfg because
> > > kernelopts appears to be empty.
> > > 
> > > In /boot/loader/entries/*kernel.conf: 
> > > options $kernelopts $tuned_params
> > > In /boot/grub2/grubenv:
> > > kernelopts=UUID=(uuid) console=tty0 crashkernel=auto console=ttyS0,115200 ro
> > > 
> > > When booting, none of these kernel options appear, only listed is linux
> > > vmlinuz*
> > > 
> > 
> > What's your grub2 package version?
> > 
> > Also, can you please share your /boot/grub2/grubenv and the BLS files in
> > /boot/loader/entries ?
> 
> My grub2 is v2.03.
> 

I meant the exact installed package version.

> grubenv:
> # GRUB Environment Block
> saved_entry=0
> kernelopts=root=UUID=7b13b9d6-cd21-44a4-aea6-05400b8410ac ro console=tty0
> rd_NO_PLYMOUTH crashkernel=auto console=ttyS0,115200
> #####
> 
> entry configuration:
> title CentOS Linux (4.18.0-80.el8.x86_64) 8 (Core)
> version 4.18.0-80.el8.x86_64
> linux /vmlinuz-4.18.0-80.el8.x86_64
> initrd /initramfs-4.18.0-80.el8.x86_64.img $tuned_initrd
> options $kernelopts $tuned_params
> id centos-20190604092737-4.18.0-80.el8.x86_64
> grub_users $grub_users
> grub_arg --unrestricted
> grub_class kernel

Can you please attach the files.

Comment 4 lidokawaiibear 2019-12-20 00:58:18 UTC
Created attachment 1646721 [details]
boot loader specification configuration

Comment 5 lidokawaiibear 2019-12-20 00:58:45 UTC
Created attachment 1646722 [details]
grubenv

Comment 6 lidokawaiibear 2019-12-20 00:59:56 UTC
(In reply to Javier Martinez Canillas from comment #3)
> (In reply to lidokawaiibear from comment #2)
> > (In reply to Javier Martinez Canillas from comment #1)
> > > (In reply to lidokawaiibear from comment #0)
> > > > Description of problem:
> > > > After install new kernel via yum, kernel does not boot with blscfg because
> > > > kernelopts appears to be empty.
> > > > 
> > > > In /boot/loader/entries/*kernel.conf: 
> > > > options $kernelopts $tuned_params
> > > > In /boot/grub2/grubenv:
> > > > kernelopts=UUID=(uuid) console=tty0 crashkernel=auto console=ttyS0,115200 ro
> > > > 
> > > > When booting, none of these kernel options appear, only listed is linux
> > > > vmlinuz*
> > > > 
> > > 
> > > What's your grub2 package version?
> > > 
> > > Also, can you please share your /boot/grub2/grubenv and the BLS files in
> > > /boot/loader/entries ?
> > 
> > My grub2 is v2.03.
> > 
> 
> I meant the exact installed package version.
> 
> > grubenv:
> > # GRUB Environment Block
> > saved_entry=0
> > kernelopts=root=UUID=7b13b9d6-cd21-44a4-aea6-05400b8410ac ro console=tty0
> > rd_NO_PLYMOUTH crashkernel=auto console=ttyS0,115200
> > #####
> > 
> > entry configuration:
> > title CentOS Linux (4.18.0-80.el8.x86_64) 8 (Core)
> > version 4.18.0-80.el8.x86_64
> > linux /vmlinuz-4.18.0-80.el8.x86_64
> > initrd /initramfs-4.18.0-80.el8.x86_64.img $tuned_initrd
> > options $kernelopts $tuned_params
> > id centos-20190604092737-4.18.0-80.el8.x86_64
> > grub_users $grub_users
> > grub_arg --unrestricted
> > grub_class kernel
> 
> Can you please attach the files.

1:2.02-66

Comment 7 Javier Martinez Canillas 2020-01-15 10:02:56 UTC
(In reply to lidokawaiibear from comment #6)

[snip]

> > 
> > Can you please attach the files.
>

These appear to be correct.
 
> 1:2.02-66

I was not able to reproduce your issue with the same version. Is this a legacy BIOS or EFI install? If the former, could you try running grub2-install /dev/X (replace X with the block device where your GRUB is installed)?

Comment 8 lidokawaiibear 2020-01-23 18:48:13 UTC
(In reply to Javier Martinez Canillas from comment #7)
> (In reply to lidokawaiibear from comment #6)
> 
> [snip]
> 
> > > 
> > > Can you please attach the files.
> >
> 
> These appear to be correct.
>  
> > 1:2.02-66
> 
> I was not able to reproduce your issue with the same version. Is this a
> legacy BIOS or EFI install? If the former, could you try running
> grub2-install /dev/X (replace X with the block device where your GRUB is
> installed)?

This was an EFI install after making it into a hybrid with gdisk's transformation. I did run grub2-install --target=i386-pc /dev/sda after.

Comment 9 Javier Martinez Canillas 2020-06-17 08:50:43 UTC
Is this issue still present? I'm not able to reproduce it.

Comment 10 Javier Martinez Canillas 2020-07-17 08:34:34 UTC
Closing since I was not able to reproduce this issue. Please feel re-open if the issue is still present.