Symptoms
During or after an ELevate upgrade, the following error appears and can prevent ELevate from completing:
CONFIG_TEXT: kernel-core-5.14.0-611.55.1.el9_7.x86_64 post-install scriptlet failed
/lib/modules/5.14.0-611.55.1.el9_7.x86_64/bls.conf: No such file or directory
Error in POSTTRANS scriptlet in rpm package kernel-core
Related errors may also appear when regenerating the rescue kernel:
CONFIG_TEXT: cp: cannot stat '/boot/bls.conf': No such file or directory
sed: can't read /boot/loader/entries/<UUID>-0-rescue.conf: No such file or directory
Cause
The /boot/loader/entries/ directory is missing a Boot Loader Spec (BLS) entry for the current kernel, or the directory is empty. The rescue kernel regeneration script depends on these BLS entries to locate required configuration files; when they're absent, the script fails with the errors above. This is generally non-fatal to the upgrade itself, but it should still be resolved so the rescue kernel is regenerated correctly.
Resolution
To fix the error and regenerate the rescue kernel properly, follow these steps:
Confirm /boot/loader/entries/ is missing entries for the current kernel:
# ls -l /boot/loader/entries/
Remove any stale or corrupted loader entries for the current kernel:
# rm -rvf /boot/loader/entries/$(uname -r)
Reinstall the current kernel package to restore the necessary boot components:
# yum reinstall kernel-core-$(uname -r)
Remove any existing rescue kernel artifacts, if present:
# rm -rvf /boot/vmlinuz-rescue /boot/initramfs-rescue
Regenerate the rescue kernel and initramfs:
# /usr/lib/kernel/install.d/51-dracut-rescue.install add "$(uname -r)" /boot "/boot/vmlinuz-$(uname -r)"
This should complete without error once the above steps are done.
Comments
0 comments
Article is closed for comments.