diff -Nru s390-tools-1.34.0/debian/changelog s390-tools-1.34.0/debian/changelog --- s390-tools-1.34.0/debian/changelog 2018-02-21 13:44:02.000000000 -0300 +++ s390-tools-1.34.0/debian/changelog 2018-04-30 11:20:25.000000000 -0300 @@ -1,3 +1,10 @@ +s390-tools (1.34.0-0ubuntu8.6) xenial; urgency=medium + + * zz-zipl: Do not run if non-optional initrds don't exist yet (LP: #1766727) + - Backport of the fix for bionic by Adam Conrad. + + -- Thadeu Lima de Souza Cascardo Mon, 30 Apr 2018 11:20:25 -0300 + s390-tools (1.34.0-0ubuntu8.5) xenial; urgency=medium * Correct postinst, which cleans up erroneous directory from diff -Nru s390-tools-1.34.0/debian/kernel/zz-zipl s390-tools-1.34.0/debian/kernel/zz-zipl --- s390-tools-1.34.0/debian/kernel/zz-zipl 2016-02-14 15:47:22.000000000 -0200 +++ s390-tools-1.34.0/debian/kernel/zz-zipl 2018-04-30 11:19:01.000000000 -0300 @@ -16,6 +16,24 @@ if [ -f /etc/zipl.conf ] then + for initrd in $(awk ' + function emit() { + if (optional == "0" && ramdisk != "") { + print(ramdisk); + }; + ramdisk=""; + optional="0"; + } + /^optional[ ]*=/ { optional=$0; sub("^optional[ ]*=[ ]*", "", optional); } + /^ramdisk[ ]*=/ { ramdisk=$0; sub("^ramdisk[ ]*=[ ]*", "", ramdisk); } + /^\[/ { emit(); } + END { emit(); } + ' < /etc/zipl.conf); do + if [ ! -f "$initrd" ]; then + echo "Not invoking zipl: initrd doesn't exist yet" >&2 + exit 0 + fi + done zipl &2 else echo "WARNING, not invoking zipl: /etc/zipl.conf not found" >&2