Update nodemgmt-scripts.sh

This commit is contained in:
2019-04-03 19:42:59 -05:00
parent 5c7841d3b0
commit 21af626dda

View File

@@ -1262,11 +1262,11 @@ SERVICE(){
nid=1 nid=1
var2=${NTYPE}_HOSTS[@] var2=${NTYPE}_HOSTS[@]
for nip in "${!var2}"; do for nip in "${!var2}"; do
if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) == *"${3}"* ]]; then GO=true; # if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) == *"${3}"* ]]; then GO=true;
#elif [ ! -z ${3+x} ] || [ "${3}" == "q" ]; then GO=true; # elif [ ! -z ${3+x} ] || [ "${3}" == "q" ]; then GO=true;
else GO=false; # else GO=false;
fi # fi
if [ "${GO}" == "true" ]; then # if [ "${GO}" == "true" ]; then
if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) == *"${nip}"* ]]; then if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) == *"${nip}"* ]]; then
nip='localhost ' nip='localhost '
NCMD='' NCMD=''
@@ -1288,7 +1288,7 @@ SERVICE(){
echo -e "${idsCL[Red]}ERROR${idsCL[Default]}" echo -e "${idsCL[Red]}ERROR${idsCL[Default]}"
fi fi
fi fi
fi # fi
nid=`expr $nid + 1` nid=`expr $nid + 1`
done done
fi fi