Update nodemgmt-scripts.sh

This commit is contained in:
2019-01-29 23:47:51 -06:00
parent 398ce044c0
commit 36cfe3cd6b

View File

@@ -158,15 +158,14 @@ case "$1" in
for srvc in "${SERVICES2[@]}" for srvc in "${SERVICES2[@]}"
do do
echo "${nip} - checking ${srvc}" echo "${nip} - checking ${srvc}"
if [ "${STATUS_CHECK_EMAIL}" != "" ]; then
if [ $(${NCMD} pgrep ${srvc} | wc -l) -lt "1" ]; then if [ $(${NCMD} pgrep ${srvc} | wc -l) -lt "1" ]; then
echo "${NM_SERVICES[${srvc}]} is down" | mail -s "iDS-Node${nid}-${nip}" ${STATUS_CHECK_EMAIL} echo "${NM_SERVICES[${srvc}]} is down" | mail -s "iDS-Node${nid}-${nip}" ${STATUS_CHECK_EMAIL}
fi fi
fi
done done
nid=`expr $nid + 1` nid=`expr $nid + 1`
done done
fi fi
fi
;; ;;
set-permissions) set-permissions)