Fix kernel-install scripts issues (#1634803)
The 91-zipl.install kernel-install script attempts to execute zipl when a kernel is installed, but this will fail if there isn't a zipl confg file. Also, the kernel-install scripts are using ',' as the sed delimiter when updating the kernel command line options in the BLS fragment file. But it is valid to have that character in a cmdline so instead use '#' for that. Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
This commit is contained in:
parent
a8d596d27b
commit
2f4b67cd1e
@ -98,7 +98,7 @@ case "$COMMAND" in
|
||||
cp -aT "${KERNEL_DIR}/bls.conf" "${BLS_TARGET}" || exit $?
|
||||
sed -i -e "s,^linux.*,linux /boot/vmlinuz-${KERNEL_VERSION},g" "${BLS_TARGET}"
|
||||
sed -i -e "s,^initrd.*,initrd /boot/initramfs-${KERNEL_VERSION}.img,g" "${BLS_TARGET}"
|
||||
sed -i -e "s,^options.*,options ${BOOT_OPTIONS[*]},g" "${BLS_TARGET}"
|
||||
sed -i -e "s#^options.*#options ${BOOT_OPTIONS[*]}#g" "${BLS_TARGET}"
|
||||
else
|
||||
mkbls "${KERNEL_VERSION}" \
|
||||
"$(date -u +%Y%m%d%H%M%S -d "$(stat -c '%y' "${KERNEL_DIR}")")" \
|
||||
@ -115,7 +115,7 @@ case "$COMMAND" in
|
||||
sed -i -e "s/^title.*/title ${TITLE}${LINUX_DEBUG_TITLE_POSTFIX}/" "${BLS_DEBUG}"
|
||||
sed -i -e "s/^version.*/version ${VERSION}${LINUX_DEBUG_VERSION_POSTFIX}/" "${BLS_DEBUG}"
|
||||
sed -i -e "s/^id.*/${BLSID}/" "${BLS_DEBUG}"
|
||||
sed -i -e "s,^options.*,options ${BOOT_OPTIONS[*]}${CMDLINE_LINUX_DEBUG}," "${BLS_DEBUG}"
|
||||
sed -i -e "s#^options.*#options ${BOOT_OPTIONS[*]}${CMDLINE_LINUX_DEBUG}#" "${BLS_DEBUG}"
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
@ -39,7 +39,7 @@ case "$COMMAND" in
|
||||
if [[ -f "${BLS_RESCUE}" ]] && grep -q '^options.*$kernelopts' "${BLS_RESCUE}"; then
|
||||
sed -i -e "s,^linux.*,linux /boot/vmlinuz-0-rescue-${MACHINE_ID},g" "${BLS_RESCUE}"
|
||||
sed -i -e "s,^initrd.*,initrd /boot/initramfs-0-rescue-${MACHINE_ID}.img,g" "${BLS_RESCUE}"
|
||||
sed -i -e "s,^options.*,options ${BOOT_OPTIONS[*]},g" "${BLS_RESCUE}"
|
||||
sed -i -e "s#^options.*#options ${BOOT_OPTIONS[*]}#g" "${BLS_RESCUE}"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
|
@ -1,5 +1,9 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [[ ! -f /etc/zipl.conf ]]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
COMMAND="$1"
|
||||
|
||||
case "$COMMAND" in
|
||||
|
@ -5,7 +5,7 @@ Name: s390utils
|
||||
Summary: Utilities and daemons for IBM z Systems
|
||||
Group: System Environment/Base
|
||||
Version: 2.6.0
|
||||
Release: 5%{?dist}
|
||||
Release: 6%{?dist}
|
||||
Epoch: 2
|
||||
License: MIT
|
||||
ExclusiveArch: s390 s390x
|
||||
@ -810,6 +810,9 @@ User-space development files for the s390/s390x architecture.
|
||||
|
||||
|
||||
%changelog
|
||||
* Mon Oct 01 2018 Dan Horák <dan[at]danny.cz> - 2:2.6.0-6
|
||||
- Fix kernel-install scripts issues
|
||||
|
||||
* Fri Sep 21 2018 Dan Horák <dan[at]danny.cz> - 2:2.6.0-5
|
||||
- Makefile cleanups
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user