Installing bootloader on POWER system fails with "symbol `grub_disk_get_size' not found"
This document (000020692) is provided subject to the disclaimer at the end of this document.
SUSE Linux Enterprise Server 15SP3
SUSE Linux Enterprise Server 15SP2
Kernel update or even installation fails with an error.
In the yast2 logs one can find e.g.
2022-06-28 11:09:46 <3> update-bootloader-9653 run_command.294: '/usr/lib/bootloader/grub2/install' failed with exit code 1, output: <<<<<<<<<<<<<<<< target = powerpc-ieee1275 + /usr/sbin/grub2-install --suse-inhibit-signed --target=powerpc-ieee1275 --force --skip-fs-probe /dev/disk/by-id/<sanitized> Installing for powerpc-ieee1275 platform. nvram: ERROR: cannot open "/dev/nvram": No such device nvram: ERROR: cannot open "/dev/misc/nvram": No such file or directory /usr/sbin/grub2-install: error: `nvsetenv' failed. You will have to set `boot-device' variable manually. At the IEEE1275 prompt, type: setenv boot-device /vdevice/vfc-client@30000015/disk@<serial-id>
Note the "nvram: ERROR: cannot open "/dev/nvram": No such device" which points to the problem
# modprobe nvram
Under rare circumstances the nvram module is not loaded and a grub2 check fails during installing the bootloader.
If the old kernel is removed, booting will fail and the system stops in
In case the system is not booting anymore already, use the following fix:
Boot a rescue system from a SLES15 SP2/3/4 installation iso.
1 - On the menu, select “Rescue system” or “more” and “Rescue system”.
2 - By default, the rescue system will activate the LVM volume group right away, which is not optimal when rescuing a system with multipath configured.
In order to deactivate the volume group, use the following command :
# vgchange -anNow, start the multipath service with :
# modprobe dm_multipath # systemctl restart multipathd
Confirm that the paths are visible with the command :
# multipath -ll
3 – Make sure that the filter in /etc/lvm/lvm.conf is set to accept only multipath devices by changing the "filter =" line as described below :
filter = [ "a|/dev/disk/by-id/dm-uuid-.*mpath.*|", "r/.*/" ]
Starting 15SP3, we don't use lvmetad anymore, so just check with
# pvscan ; vgscan
If set correctly, the “pvscan” command shouldn't output "Found duplicate PV" messages.
If it does, or if no devices at all are shown, the filter is wrong. Check for typos.
4 – Mount the root LV using /dev/mapper and bind /proc, /dev, /sys and /run to it:
# vgchange -ay # mount /dev/mapper/system-root /mnt # mount /dev/mapper/system-usr /mnt/usr <---Necessary only if /usr is a separate partition! # for i in /dev /proc /sys /run ; do mount -o bind /$i /mnt/$i ; done
5 - Now the nvram kernel module must be loaded!
# modprobe nvram
6 - Make sure the LVM filter in the installed system is set similar to the above.
7 - Next change root to /mnt
# chroot /mnt # mount -a
and check if all local volumes are mounted correctly
8 - First, determine the PReP partition. It is mandatory to boot the system and should be the first partition on the disk, size typically between 4 and 12MB, so, pretty small.
# fdisk -l | less
Then proceed with reinstalling grub2 into the PReP partition found above:
# grub2-install /dev/mapper/360000000000000000000000000000000-part1 # EXAMPLE!
Then exit chroot and reboot.
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:000020692
- Creation Date: 18-Jul-2022
- Modified Date:18-Jul-2022
- SUSE Linux Enterprise Server
- SUSE Linux Enterprise Server for SAP Applications
For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com