From 920f542ef11544fb073986d859ef919c975a6355 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Thu, 12 Dec 2019 23:38:37 -0600 Subject: [PATCH] Update nodemgmt-scripts.sh --- nodemgmt-scripts.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nodemgmt-scripts.sh b/nodemgmt-scripts.sh index 11e7a80a..f6a0b59b 100755 --- a/nodemgmt-scripts.sh +++ b/nodemgmt-scripts.sh @@ -379,7 +379,9 @@ STATUS(){ DIVIDER false green fi declare -A partitions - partitions=`${NCMD} df -hBM | grep -vE '^Filesystem|tmpfs|cdrom' | awk '{ print $5 " " $1 }' | while read output; do echo $output | awk '{ print $2 }'; done` + partitions=`${NCMD} df -hBM | grep -vE '^Filesystem|tmpfs|cdrom' | awk '{ print $5 " " $1 }' | while read output; do echo $output | awk '{ print $2 }'; done;` + partitions=`echo ${partitions[*]}` + echo $partitions; for partition in "${partitions[@]}"; do freespace=`${NCMD} df -hPBM ${partition} | awk '{print $5}' |tail -1|sed 's/%$//g'` echo -en " ${partition}$spc: "