From ee37ba8aafcbe9ac13f55b7e406d439cdcfa80c767ba624a33cb775da815aac7 Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Thu, 14 Jun 2018 12:01:04 +0000 Subject: [PATCH 1/2] Accepting request 616849 from home:dmolkentin:branches:Base:System - 95multipath: Pickup multipath files in /etc/multipath/conf.d (boo#1048551) * adds 0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch - 10i18n: Load all keymaps for a given locale (boo#1065058) * adds 0569-10i18n-Load-all-keymaps-for-a-given-locale.patch * adds 0570-10i18n-Fix-possible-infinite-recursion.patch OBS-URL: https://build.opensuse.org/request/show/616849 OBS-URL: https://build.opensuse.org/package/show/Base:System/dracut?expand=0&rev=351 --- ...Pickup-files-in-etc-multipath-conf.d.patch | 27 +++++++ ...-Load-all-keymaps-for-a-given-locale.patch | 71 +++++++++++++++++++ ...i18n-Fix-possible-infinite-recursion.patch | 25 +++++++ dracut.changes | 10 +++ dracut.spec | 9 +++ 5 files changed, 142 insertions(+) create mode 100644 0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch create mode 100644 0569-10i18n-Load-all-keymaps-for-a-given-locale.patch create mode 100644 0570-10i18n-Fix-possible-infinite-recursion.patch diff --git a/0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch b/0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch new file mode 100644 index 0000000..4d8fb1c --- /dev/null +++ b/0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch @@ -0,0 +1,27 @@ +From 05f1365ffd1c03bad44fdbb312769044cda032a8 Mon Sep 17 00:00:00 2001 +From: Daniel Molkentin +Date: Fri, 14 Jul 2017 14:21:43 +0200 +Subject: [PATCH] 95multipath: Pickup files in /etc/multipath/conf.d + +Reference: boo#1048551 +--- + modules.d/90multipath/module-setup.sh | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/modules.d/90multipath/module-setup.sh b/modules.d/90multipath/module-setup.sh +index 85848068..4e059b41 100755 +--- a/modules.d/90multipath/module-setup.sh ++++ b/modules.d/90multipath/module-setup.sh +@@ -92,7 +92,8 @@ install() { + xdrgetprio \ + /etc/xdrdevices.conf \ + /etc/multipath.conf \ +- /etc/multipath/* ++ /etc/multipath/* \ ++ /etc/multipath/conf.d/* + + inst $(command -v partx) /sbin/partx + +-- +2.12.3 + diff --git a/0569-10i18n-Load-all-keymaps-for-a-given-locale.patch b/0569-10i18n-Load-all-keymaps-for-a-given-locale.patch new file mode 100644 index 0000000..72cc790 --- /dev/null +++ b/0569-10i18n-Load-all-keymaps-for-a-given-locale.patch @@ -0,0 +1,71 @@ +From afd09c9a87ef09e2595f71fdae1d38ac00cfd071 Mon Sep 17 00:00:00 2001 +From: Daniel Molkentin +Date: Thu, 26 Oct 2017 14:59:34 +0200 +Subject: [PATCH 1/2] 10i18n: Load all keymaps for a given locale + +Previously, dracut would only copy the first one found. However, +with legacy maps for some locales around, there is a chance we +pick the wrong one. Pick all matching keymaps instead + +Reference: boo#1065058 +--- + modules.d/10i18n/module-setup.sh | 35 ++++++++++++++++++++--------------- + 1 file changed, 20 insertions(+), 15 deletions(-) + +diff --git a/modules.d/10i18n/module-setup.sh b/modules.d/10i18n/module-setup.sh +index d6aab19f..be4ada54 100755 +--- a/modules.d/10i18n/module-setup.sh ++++ b/modules.d/10i18n/module-setup.sh +@@ -30,21 +30,24 @@ install() { + + # This is from 10redhat-i18n. + findkeymap () { +- local MAP=$1 ++ local MAPS=$1 + local MAPNAME=${1%.map*} +- [[ ! -f $MAP ]] && \ +- MAP=$(find ${kbddir}/keymaps -type f -name ${MAPNAME} -o -name ${MAPNAME}.map -o -name ${MAPNAME}.map.\* | head -n1) +- [[ " $KEYMAPS " = *" $MAP "* ]] && return +- KEYMAPS="$KEYMAPS $MAP" +- case $MAP in +- *.gz) cmd=zgrep;; +- *.bz2) cmd=bzgrep;; +- *) cmd=grep ;; +- esac +- +- for INCL in $($cmd "^include " $MAP | while read a a b || [ -n "$a" ]; do echo ${a//\"/}; done); do +- for FN in $(find ${kbddir}/keymaps -type f -name $INCL\*); do +- findkeymap $FN ++ local map ++ [[ ! -f $MAPS ]] && \ ++ MAPS=$(find ${kbddir}/keymaps -type f -name ${MAPNAME} -o -name ${MAPNAME}.map -o -name ${MAPNAME}.map.\*) ++ ++ for map in $MAPS; do ++ KEYMAPS="$KEYMAPS $map" ++ case $map in ++ *.gz) cmd=zgrep;; ++ *.bz2) cmd=bzgrep;; ++ *) cmd=grep ;; ++ esac ++ ++ for INCL in $($cmd "^include " $map | while read a a b || [ -n "$a" ]; do echo ${a//\"/}; done); do ++ for FN in $(find ${kbddir}/keymaps -type f -name $INCL\*); do ++ findkeymap $FN ++ done + done + done + } +@@ -185,7 +188,9 @@ install() { + findkeymap ${map} + done + +- inst_opt_decompress ${KEYMAPS} ++ for keymap in ${KEYMAPS}; do ++ inst_opt_decompress ${keymap} ++ done + + inst_opt_decompress ${kbddir}/consolefonts/${DEFAULT_FONT}.* + +-- +2.16.3 + diff --git a/0570-10i18n-Fix-possible-infinite-recursion.patch b/0570-10i18n-Fix-possible-infinite-recursion.patch new file mode 100644 index 0000000..2f42745 --- /dev/null +++ b/0570-10i18n-Fix-possible-infinite-recursion.patch @@ -0,0 +1,25 @@ +From a4e11a0e4d6fbed25244cc0f01732f81841bd642 Mon Sep 17 00:00:00 2001 +From: Daniel Molkentin +Date: Fri, 27 Apr 2018 16:59:47 +0200 +Subject: [PATCH 2/2] 10i18n: Fix possible infinite recursion + +--- + modules.d/10i18n/module-setup.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/modules.d/10i18n/module-setup.sh b/modules.d/10i18n/module-setup.sh +index be4ada54..9083e98f 100755 +--- a/modules.d/10i18n/module-setup.sh ++++ b/modules.d/10i18n/module-setup.sh +@@ -46,7 +46,7 @@ install() { + + for INCL in $($cmd "^include " $map | while read a a b || [ -n "$a" ]; do echo ${a//\"/}; done); do + for FN in $(find ${kbddir}/keymaps -type f -name $INCL\*); do +- findkeymap $FN ++ strstr "$KEYMAPS" "$FN" || findkeymap $FN + done + done + done +-- +2.16.3 + diff --git a/dracut.changes b/dracut.changes index 53f1215..bff67c3 100644 --- a/dracut.changes +++ b/dracut.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Thu Jun 14 11:48:42 UTC 2018 - daniel.molkentin@suse.com + +- 95multipath: Pickup multipath files in /etc/multipath/conf.d (boo#1048551) + * adds 0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch + +- 10i18n: Load all keymaps for a given locale (boo#1065058) + * adds 0569-10i18n-Load-all-keymaps-for-a-given-locale.patch + * adds 0570-10i18n-Fix-possible-infinite-recursion.patch + ------------------------------------------------------------------- Wed Apr 25 16:50:06 UTC 2018 - daniel.molkentin@suse.com diff --git a/dracut.spec b/dracut.spec index 04367d3..e3c6bb8 100644 --- a/dracut.spec +++ b/dracut.spec @@ -390,6 +390,12 @@ Patch565: 0565-90kernel-modules-Include-Intel-Volume-Management-Dev.patch Patch566: 0566-95nfs-If-no-server-is-configured-read-BOOTSERVERADDR.patch # Patch specific to SUSE, upstream only documentation Patch567: 0567-Fix-booting-with-fips-1-on-SLES-15.patch +# Applied upstream as d000b9a2c7837be7d1c71fb730675f822cf96fc1 +Patch568: 0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch +# Applied upstream as afd09c9a87ef09e2595f71fdae1d38ac00cfd071 +Patch569: 0569-10i18n-Load-all-keymaps-for-a-given-locale.patch +# Applied upstream as a4e11a0e4d6fbed25244cc0f01732f81841bd642 +Patch570: 0570-10i18n-Fix-possible-infinite-recursion.patch BuildRequires: asciidoc BuildRequires: bash @@ -680,6 +686,9 @@ chmod a+x modules.d/95qeth_rules/module-setup.sh %patch565 -p1 %patch566 -p1 %patch567 -p1 +%patch568 -p1 +%patch569 -p1 +%patch570 -p1 %build %configure\ From b3304145628520ffc365d81d1425f8c7d993c15751a41360817b2b6396bff34c Mon Sep 17 00:00:00 2001 From: Daniel Molkentin Date: Thu, 14 Jun 2018 13:01:21 +0000 Subject: [PATCH 2/2] Accepting request 616866 from home:dmolkentin:branches:Base:System - 40network: Fix static network setup (bsc#1091099) * adds 0571-40network-Fix-static-network-setup.patch - lsinitrd: Fix cat: write error: Broken pipe error (bsc#1094603) * adds 0572-lsinitrd-no-more-cat-write-error-Broken-pipe.patch * adds 0573-lsinitrd.sh-quote-filename-in-extract_files.patch OBS-URL: https://build.opensuse.org/request/show/616866 OBS-URL: https://build.opensuse.org/package/show/Base:System/dracut?expand=0&rev=352 --- 0571-40network-Fix-static-network-setup.patch | 28 ++++++++++++ ...-no-more-cat-write-error-Broken-pipe.patch | 44 +++++++++++++++++++ ...d.sh-quote-filename-in-extract_files.patch | 25 +++++++++++ dracut.changes | 10 +++++ dracut.spec | 8 ++++ 5 files changed, 115 insertions(+) create mode 100644 0571-40network-Fix-static-network-setup.patch create mode 100644 0572-lsinitrd-no-more-cat-write-error-Broken-pipe.patch create mode 100644 0573-lsinitrd.sh-quote-filename-in-extract_files.patch diff --git a/0571-40network-Fix-static-network-setup.patch b/0571-40network-Fix-static-network-setup.patch new file mode 100644 index 0000000..18abf1c --- /dev/null +++ b/0571-40network-Fix-static-network-setup.patch @@ -0,0 +1,28 @@ +From a3fdbedce43956881ca01c94543b22e37d205da6 Mon Sep 17 00:00:00 2001 +From: Daniel Molkentin +Date: Thu, 14 Jun 2018 14:18:44 +0200 +Subject: [PATCH] 40network: Fix static network setup + +Patch-by: Thomas Blume + +References: bsc#1091099 +--- + modules.d/40network/ifup.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh +index 2d93cebd..13564778 100755 +--- a/modules.d/40network/ifup.sh ++++ b/modules.d/40network/ifup.sh +@@ -275,7 +275,7 @@ do_ifcfg() { + dhcp*) + do_dhcp -4 ;; + *) +- do_static ;; ++ ;; + esac + # loop over all configurations in ifcfg-$netif (IPADDR*) and apply + for conf in ${!IPADDR@}; do +-- +2.16.3 + diff --git a/0572-lsinitrd-no-more-cat-write-error-Broken-pipe.patch b/0572-lsinitrd-no-more-cat-write-error-Broken-pipe.patch new file mode 100644 index 0000000..3a37809 --- /dev/null +++ b/0572-lsinitrd-no-more-cat-write-error-Broken-pipe.patch @@ -0,0 +1,44 @@ +From b2e09d1d444e771493c26c576256f962bd8869f3 Mon Sep 17 00:00:00 2001 +From: Harald Hoyer +Date: Tue, 16 Jan 2018 12:14:15 +0100 +Subject: [PATCH 1/2] lsinitrd: no more cat: write error: Broken pipe + +silence the cat +--- + lsinitrd.sh | 7 +++---- + 1 file changed, 3 insertions(+), 4 deletions(-) + +diff --git a/lsinitrd.sh b/lsinitrd.sh +index 1e4d99ac..9c7a178b 100755 +--- a/lsinitrd.sh ++++ b/lsinitrd.sh +@@ -120,7 +120,7 @@ extract_files() + for f in "${!filenames[@]}"; do + [[ $nofileinfo ]] || echo "initramfs:/$f" + [[ $nofileinfo ]] || echo "========================================================================" +- $CAT $image | cpio --extract --verbose --quiet --to-stdout $f 2>/dev/null ++ $CAT "$image" 2>/dev/null | cpio --extract --verbose --quiet --to-stdout $f 2>/dev/null + ((ret+=$?)) + [[ $nofileinfo ]] || echo "========================================================================" + [[ $nofileinfo ]] || echo +@@ -139,15 +139,14 @@ list_files() + { + echo "========================================================================" + if [ "$sorted" -eq 1 ]; then +- $CAT "$image" | cpio --extract --verbose --quiet --list | sort -n -k5 ++ $CAT "$image" 2>/dev/null | cpio --extract --verbose --quiet --list | sort -n -k5 + else +- $CAT "$image" | cpio --extract --verbose --quiet --list | sort -k9 ++ $CAT "$image" 2>/dev/null | cpio --extract --verbose --quiet --list | sort -k9 + fi + ((ret+=$?)) + echo "========================================================================" + } + +- + if (( ${#filenames[@]} <= 0 )); then + echo "Image: $image: $(du -h $image | while read a b || [ -n "$a" ]; do echo $a;done)" + echo "========================================================================" +-- +2.16.3 + diff --git a/0573-lsinitrd.sh-quote-filename-in-extract_files.patch b/0573-lsinitrd.sh-quote-filename-in-extract_files.patch new file mode 100644 index 0000000..ce4805d --- /dev/null +++ b/0573-lsinitrd.sh-quote-filename-in-extract_files.patch @@ -0,0 +1,25 @@ +From 0bb520ee706a0927f538004e2acb50d8c2b469b3 Mon Sep 17 00:00:00 2001 +From: Harald Hoyer +Date: Thu, 18 Jan 2018 10:17:42 +0100 +Subject: [PATCH 2/2] lsinitrd.sh: quote filename in extract_files() + +--- + lsinitrd.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lsinitrd.sh b/lsinitrd.sh +index 9c7a178b..da7bf044 100755 +--- a/lsinitrd.sh ++++ b/lsinitrd.sh +@@ -120,7 +120,7 @@ extract_files() + for f in "${!filenames[@]}"; do + [[ $nofileinfo ]] || echo "initramfs:/$f" + [[ $nofileinfo ]] || echo "========================================================================" +- $CAT "$image" 2>/dev/null | cpio --extract --verbose --quiet --to-stdout $f 2>/dev/null ++ $CAT "$image" 2>/dev/null | cpio --extract --verbose --quiet --to-stdout "$f" 2>/dev/null + ((ret+=$?)) + [[ $nofileinfo ]] || echo "========================================================================" + [[ $nofileinfo ]] || echo +-- +2.16.3 + diff --git a/dracut.changes b/dracut.changes index bff67c3..a361367 100644 --- a/dracut.changes +++ b/dracut.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Thu Jun 14 12:26:02 UTC 2018 - daniel.molkentin@suse.com + +- 40network: Fix static network setup (bsc#1091099) + * adds 0571-40network-Fix-static-network-setup.patch + +- lsinitrd: Fix cat: write error: Broken pipe error (bsc#1094603) + * adds 0572-lsinitrd-no-more-cat-write-error-Broken-pipe.patch + * adds 0573-lsinitrd.sh-quote-filename-in-extract_files.patch + ------------------------------------------------------------------- Thu Jun 14 11:48:42 UTC 2018 - daniel.molkentin@suse.com diff --git a/dracut.spec b/dracut.spec index e3c6bb8..9c9780b 100644 --- a/dracut.spec +++ b/dracut.spec @@ -396,6 +396,11 @@ Patch568: 0568-95multipath-Pickup-files-in-etc-multipath-conf.d.patch Patch569: 0569-10i18n-Load-all-keymaps-for-a-given-locale.patch # Applied upstream as a4e11a0e4d6fbed25244cc0f01732f81841bd642 Patch570: 0570-10i18n-Fix-possible-infinite-recursion.patch +Patch571: 0571-40network-Fix-static-network-setup.patch +# Patch adopted from upstream commit bce6823a19b3fc0be50ff5c29c5ef90fa58b3430 +Patch572: 0572-lsinitrd-no-more-cat-write-error-Broken-pipe.patch +# Patch adopted from upstream commit 8379784a0e8e38b85f36cb605a323dce02fd76b5 +Patch573: 0573-lsinitrd.sh-quote-filename-in-extract_files.patch BuildRequires: asciidoc BuildRequires: bash @@ -689,6 +694,9 @@ chmod a+x modules.d/95qeth_rules/module-setup.sh %patch568 -p1 %patch569 -p1 %patch570 -p1 +%patch571 -p1 +%patch572 -p1 +%patch573 -p1 %build %configure\