-
Bug
-
Resolution: Done-Errata
-
Normal
-
rhel-8.5.0
-
grub2-2.02-151.el8
-
None
-
Moderate
-
rhel-sst-desktop-firmware-bootloaders
-
None
-
False
-
-
None
-
None
-
If docs needed, set a value
-
-
ppc64le
-
None
Description of problem:
On PPC64LE platforms we disable GRUB_ENABLE_BLSCFG=true to force having a completely hardcoded grub2.cfg file with "menuentry" items.
This works fine except the $kernelopts variable is not designed as fallback in case grubenv is broken.
Following snippet is missing:
-------- 8< ---------------- 8< ---------------- 8< ---------------- 8< --------
- The kernelopts variable should be defined in the grubenv file. But to ensure that menu
- entries populated from BootLoaderSpec files that use this variable work correctly even
- without a grubenv file, define a fallback kernelopts variable if this has not been set.
# - The kernelopts variable in the grubenv file can be modified using the grubby tool or by
- executing the grub2-mkconfig tool. For the latter, the values of the GRUB_CMDLINE_LINUX
- and GRUB_CMDLINE_LINUX_DEFAULT options from /etc/default/grub file are used to set both
- the kernelopts variable in the grubenv file and the fallback kernelopts variable.
if [ -z "${kernelopts}" ]; then
set kernelopts="..."
fi-
-
-
-
-
-
- 8< ---------------- 8< ---------------- 8< ---------------- 8< --------
-
-
-
-
-
-
Version-Release number of selected component (if applicable):
grub2-2.02-106.el8
How reproducible:
Always
Steps to Reproduce:
1. Generate the file on PPC64le
- grub2-mkconfig -o /tmp/foo
2. Check content
- grep kernelopts /tmp/foo
linux /vmlinuz-4.18.0-147.el8.ppc64le $kernelopts $tuned_params
linux /vmlinuz-0-rescue-3199ef9eefd840ffb6e94a87b592a6ea $kernelopts
Actual results:
No fallback "if [ -z "${kernelopts}" ]; then ... fi" code
Expected results:
Fallback snippet from /etc/grub.d/10_linux found on x86_64 systems
- links to
-
RHBA-2023:124644 grub2 bug fix and enhancement update