From f261f90231e2484a58b363453306e5023cd7d6ab Mon Sep 17 00:00:00 2001 From: Lichen Liu Date: Mon, 13 Jan 2025 10:34:14 +0800 Subject: [PATCH] Release kdump-utils-1.0.51-3 Resolves: RHEL-24543 Signed-off-by: Lichen Liu --- ...-correct-exit-code-of-rebuild-initrd.patch | 44 ------- ...w-ssh-opts-to-be-processed-correctly.patch | 115 ------------------ sources | 3 - 3 files changed, 162 deletions(-) delete mode 100644 0001-Return-the-correct-exit-code-of-rebuild-initrd.patch delete mode 100644 0002-Allow-ssh-opts-to-be-processed-correctly.patch diff --git a/0001-Return-the-correct-exit-code-of-rebuild-initrd.patch b/0001-Return-the-correct-exit-code-of-rebuild-initrd.patch deleted file mode 100644 index 5e721ce..0000000 --- a/0001-Return-the-correct-exit-code-of-rebuild-initrd.patch +++ /dev/null @@ -1,44 +0,0 @@ -From f6e00948aba7c31f722af79ed72c4020868dcad7 Mon Sep 17 00:00:00 2001 -From: Tao Liu -Date: Fri, 18 Oct 2024 21:45:03 +1300 -Subject: [PATCH] Return the correct exit code of rebuild initrd - -Resolves: https://issues.redhat.com/browse/RHEL-63047 - -The exit code of rebuild_initrd() should be either of -rebuild_kdump/fadump_initrd(), rather than set_vmcore_creation_status(), -otherwise it will cause a regression when rebuild initrd fails. - -Fixes: 88525ebf ("Introduce vmcore creation notification to kdump") - -Signed-off-by: Tao Liu ---- - kdumpctl | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/kdumpctl b/kdumpctl -index 82b7fb1..0140eeb 100755 ---- a/kdumpctl -+++ b/kdumpctl -@@ -173,6 +173,7 @@ rebuild_kdump_initrd() - - rebuild_initrd() - { -+ local _ret - dinfo "Rebuilding $TARGET_INITRD" - - if [[ ! -w $(dirname "$TARGET_INITRD") ]]; then -@@ -185,8 +186,10 @@ rebuild_initrd() - else - rebuild_kdump_initrd - fi -+ _ret=$? - - set_vmcore_creation_status 'clear' "$VMCORE_CREATION_STATUS" -+ return $_ret - } - - #$1: the files to be checked with IFS=' ' --- -2.40.1 - diff --git a/0002-Allow-ssh-opts-to-be-processed-correctly.patch b/0002-Allow-ssh-opts-to-be-processed-correctly.patch deleted file mode 100644 index 561f11e..0000000 --- a/0002-Allow-ssh-opts-to-be-processed-correctly.patch +++ /dev/null @@ -1,115 +0,0 @@ -From 4244c20ba021e8563a9f0bc297060338ed3a1158 Mon Sep 17 00:00:00 2001 -From: Coiby Xu -Date: Tue, 15 Oct 2024 15:11:48 +0800 -Subject: [PATCH 2/2] Allow ssh opts to be processed correctly - -Resolves: https://github.com/rhkdump/kdump-utils/issues/46 - -ssh opts shouldn't be quoted otherwise it will be treated as one -argument. For clarity, also rename ssh_opt to ssh_opts. - -Fixes: 7218f584 ("99kdumpbase: fix shellcheck warnings") -Reported-by: Jean-Baptiste Trystram -Signed-off-by: Coiby Xu ---- - dracut/99kdumpbase/kdump.sh | 43 +++++++++++++++++++++++-------------- - 1 file changed, 27 insertions(+), 16 deletions(-) - -diff --git a/dracut/99kdumpbase/kdump.sh b/dracut/99kdumpbase/kdump.sh -index e35a76d..00a61f9 100755 ---- a/dracut/99kdumpbase/kdump.sh -+++ b/dracut/99kdumpbase/kdump.sh -@@ -396,7 +396,7 @@ dump_raw() { - # $2: ssh address in @ format - dump_ssh() { - _ret=0 -- _ssh_opt="-i $1 -o BatchMode=yes -o StrictHostKeyChecking=yes" -+ _ssh_opts="-i $1 -o BatchMode=yes -o StrictHostKeyChecking=yes" - _ssh_dir="$KDUMP_PATH/$HOST_IP-$DATEDIR" - if is_ipv6_address "$2"; then - _scp_address=${2%@*}@"[${2#*@}]" -@@ -407,31 +407,37 @@ dump_ssh() { - dinfo "saving to $2:$_ssh_dir" - - cat /var/lib/random-seed > /dev/urandom -- ssh -q "$_ssh_opt" "$2" mkdir -p "$_ssh_dir" || return 1 -+ # shellcheck disable=SC2086 # ssh_opts needs to be split -+ ssh -q $_ssh_opts "$2" mkdir -p "$_ssh_dir" || return 1 - -- save_vmcore_dmesg_ssh "$DMESG_COLLECTOR" "$_ssh_dir" "$_ssh_opt" "$2" -+ save_vmcore_dmesg_ssh "$DMESG_COLLECTOR" "$_ssh_dir" "$_ssh_opts" "$2" - - dinfo "saving vmcore" - - KDUMP_LOG_DEST=$2:$_ssh_dir/ -- KDUMP_LOG_OP="scp -q $_ssh_opt '$KDUMP_LOG_FILE' '$_scp_address:$_ssh_dir/'" -+ KDUMP_LOG_OP="scp -q $_ssh_opts '$KDUMP_LOG_FILE' '$_scp_address:$_ssh_dir/'" - -- save_opalcore_ssh "$_ssh_dir" "$_ssh_opt" "$2" "$_scp_address" -+ save_opalcore_ssh "$_ssh_dir" "$_ssh_opts" "$2" "$_scp_address" - - if [ "${CORE_COLLECTOR%%[[:blank:]]*}" = "scp" ]; then -- scp -q "$_ssh_opt" /proc/vmcore "$_scp_address:$_ssh_dir/vmcore-incomplete" -+ # shellcheck disable=SC2086 # ssh_opts needs to be split -+ scp -q $_ssh_opts /proc/vmcore "$_scp_address:$_ssh_dir/vmcore-incomplete" - _ret=$? - _vmcore="vmcore" - else -- # shellcheck disable=SC2029 -- $CORE_COLLECTOR /proc/vmcore | ssh "$_ssh_opt" "$2" "umask 0077 && dd bs=512 of='$_ssh_dir/vmcore-incomplete'" -+ # shellcheck disable=SC2029,SC2086 -+ # - _ssh_opts needs to be split -+ # - _ssh_dir needs to be expanded -+ $CORE_COLLECTOR /proc/vmcore | ssh $_ssh_opts "$2" "umask 0077 && dd bs=512 of='$_ssh_dir/vmcore-incomplete'" - _ret=$? - _vmcore="vmcore.flat" - fi - - if [ $_ret -eq 0 ]; then -- # shellcheck disable=SC2029 -- ssh "$_ssh_opt" "$2" "mv '$_ssh_dir/vmcore-incomplete' '$_ssh_dir/$_vmcore'" -+ # shellcheck disable=SC2029,SC2086 -+ # - _ssh_opts needs to be split -+ # - _ssh_dir needs to be expanded -+ ssh $_ssh_opts "$2" "mv '$_ssh_dir/vmcore-incomplete' '$_ssh_dir/$_vmcore'" - _ret=$? - if [ $_ret -ne 0 ]; then - derror "moving vmcore failed, exitcode:$_ret" -@@ -461,13 +467,16 @@ save_opalcore_ssh() { - - dinfo "saving opalcore:$OPALCORE to $3:$1" - -- if ! scp "$2" "$OPALCORE" "$4:$1/opalcore-incomplete"; then -+ # shellcheck disable=SC2086 # $2 (_ssh_opts) needs to be split -+ if ! scp $2 "$OPALCORE" "$4:$1/opalcore-incomplete"; then - derror "saving opalcore failed" - return 1 - fi - -- # shellcheck disable=SC2029 -- ssh "$2" "$3" mv "$1/opalcore-incomplete" "$1/opalcore" -+ # shellcheck disable=SC2029,SC2086 -+ # - $1 (dump path) needs to be expanded -+ # - $2 (_ssh_opts) needs to be split -+ ssh $2 "$3" mv "$1/opalcore-incomplete" "$1/opalcore" - dinfo "saving opalcore complete" - return 0 - } -@@ -478,9 +487,11 @@ save_opalcore_ssh() { - # $4: ssh address in @ format - save_vmcore_dmesg_ssh() { - dinfo "saving vmcore-dmesg.txt to $4:$2" -- # shellcheck disable=SC2029 -- if "$1" /proc/vmcore | ssh "$3" "$4" "umask 0077 && dd of='$2/vmcore-dmesg-incomplete.txt'"; then -- ssh -q "$3" "$4" mv "$2/vmcore-dmesg-incomplete.txt" "$2/vmcore-dmesg.txt" -+ # shellcheck disable=SC2029,SC2086 -+ # - $2 (_ssh_dir) needs to be expanded -+ # - $3 (_ssh_opts) needs to be split -+ if "$1" /proc/vmcore | ssh $3 "$4" "umask 0077 && dd of='$2/vmcore-dmesg-incomplete.txt'"; then -+ ssh -q $3 "$4" mv "$2/vmcore-dmesg-incomplete.txt" "$2/vmcore-dmesg.txt" - dinfo "saving vmcore-dmesg.txt complete" - else - derror "saving vmcore-dmesg.txt failed" --- -2.47.0 - diff --git a/sources b/sources index b71785a..1a150a9 100644 --- a/sources +++ b/sources @@ -1,4 +1 @@ -SHA512 (kdump-utils-1.0.42.tar.gz) = 2d8717a010bfbffd4410ef57ade1402316cda07faa1063631b8665ac273fac618bff0afd9bdc02292c859d956790e06a51d81b141db158957ef97eb8408111c4 -SHA512 (kdump-utils-1.0.43.tar.gz) = ede87a85f63f1f08aec477729a2fe7858d78bd21588b00d13c8ce25b6d951bd400a0642bc2ae34c62ebcce54b8b8ff0c7a8d1d867be18217c9b015adc4131707 -SHA512 (kdump-utils-1.0.45.tar.gz) = 4df7136473978cdf80690cb25f1e4a5bde6c6b2e4e99940a06210b4a8e491afb0918a63fc4590fcac2379122fec6e9369e1370ec9ce6fcdbe2e80102e43a023d SHA512 (kdump-utils-1.0.51.tar.gz) = 4dcad4cfa8f4434e93d712675de296a49791e430b4f697c8dcfbaddbe148b53f5ef5a77d022cf7175a7650d907346def77139370ffd27ef2f6a0f6b8c9dbfa12