From 3ecd60aa289decc55be2bb6e62af76bd12308062 Mon Sep 17 00:00:00 2001 From: Wai Yee Wong Date: Fri, 24 Jul 2020 16:11:22 -0400 Subject: [PATCH 1/2] Change the regex in post.xcat.ng so that postscirpts with long filenames can still be downloaded from MN/SN to CN. --- xCAT-server/share/xcat/install/scripts/post.xcat.ng | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xCAT-server/share/xcat/install/scripts/post.xcat.ng b/xCAT-server/share/xcat/install/scripts/post.xcat.ng index 255298db8..b81e56cfa 100644 --- a/xCAT-server/share/xcat/install/scripts/post.xcat.ng +++ b/xCAT-server/share/xcat/install/scripts/post.xcat.ng @@ -134,7 +134,7 @@ function download_recursive() [ "$?" -ne "0" ] && return 1 ;; esac - done < <(curl --fail --retry 20 --max-time 60 "${url}/" | grep -o '\1' | cut -d '"' -f 2) + done < <(curl --fail --retry 20 --max-time 60 "${url}/" | grep -o '.*' | cut -d '"' -f 2) return 0 } From b082229c39c549eb9e7b75f88bdf58ab2c5754ce Mon Sep 17 00:00:00 2001 From: Wai Yee Wong Date: Tue, 4 Aug 2020 11:56:39 -0400 Subject: [PATCH 2/2] Add egrep -v "O=D|Directory" to remove irrelevant files from being copied from MN to CN. --- xCAT-server/share/xcat/install/scripts/post.xcat.ng | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xCAT-server/share/xcat/install/scripts/post.xcat.ng b/xCAT-server/share/xcat/install/scripts/post.xcat.ng index b81e56cfa..cbbad65be 100644 --- a/xCAT-server/share/xcat/install/scripts/post.xcat.ng +++ b/xCAT-server/share/xcat/install/scripts/post.xcat.ng @@ -134,7 +134,7 @@ function download_recursive() [ "$?" -ne "0" ] && return 1 ;; esac - done < <(curl --fail --retry 20 --max-time 60 "${url}/" | grep -o '.*' | cut -d '"' -f 2) + done < <(curl --fail --retry 20 --max-time 60 "${url}/" | grep -o '.*' | egrep -v "O=D|Directory" | cut -d '"' -f 2) return 0 }