From 7babbb04df2c037c58c141e71e01824d246f9432 Mon Sep 17 00:00:00 2001 From: Javier Martinez Canillas Date: Tue, 6 Nov 2018 11:47:22 +0100 Subject: [PATCH] grubby-bls: only compare using relative paths if /boot is a mount point The grub2 bootloader expects the BLS linux and initrd fields values to be set to a relative path to the root of the boot partition and the zipl tool expects these to be an absolute path to the kernel and initramfs images. So the grubby wrapper was removing the prefixes from the kernel and initrd paths before doing any comparision with the BLS fields. But this shouldn't be done if the /boot directory isn't a mount point. Resolves: rhbz#1642078 Signed-off-by: Javier Martinez Canillas --- grubby-bls | 2 +- grubby.spec | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/grubby-bls b/grubby-bls index cf9f593..ee28802 100755 --- a/grubby-bls +++ b/grubby-bls @@ -686,7 +686,7 @@ if [[ -n $display_info ]]; then display_info_values "${display_info}" fi -if [[ $bootloader = grub2 ]]; then +if [[ $bootloader = grub2 ]] && grep -q /boot /proc/mounts; then remove_var_prefix fi diff --git a/grubby.spec b/grubby.spec index e75d1d8..a5ecffc 100644 --- a/grubby.spec +++ b/grubby.spec @@ -151,6 +151,8 @@ current boot environment. Resolves: rhbz#1634752 - grubby-bls: fix --default-* options for s390x Resolves: rhbz#1644608 +- grubby-bls: only compare using relative paths if /boot is a mount point + Resolves: rhbz#1642078 * Fri Aug 10 2018 Javier Martinez Canillas - 8.40-18 - Make installkernel to use kernel-install scripts on BLS configuration