This commit is contained in:
2019-01-28 13:15:57 -06:00
parent 20a93cca7c
commit a348f08d06
2 changed files with 7 additions and 7 deletions

View File

@@ -43,7 +43,7 @@ case "$1" in
fi
echo -en "${ADISP}ing Node ${nid} ($nip)...${idsCL[Default]}"
$NCMD systemctl $3 $2
if [[ $(${NCMD} pgrep ${2} | wc -l) -gt "1" ]]; then
if [[ $(${NCMD} pgrep ${2} | wc -l) -gt "0" ]]; then
echo -e "${idsCL[Green]}OK${idsCL[Default]}"
elif [ "$3" = "Stop" ]; then echo -e "${idsCL[Red]}STOPPED${idsCL[Default]}"
else echo -e "${idsCL[Red]}ERROR${idsCL[Default]}"