Update nodemgmt-scripts.sh
This commit is contained in:
@@ -451,6 +451,8 @@ STATUS(){
|
|||||||
else
|
else
|
||||||
timeout=`date --date='2 minutes' +%s`
|
timeout=`date --date='2 minutes' +%s`
|
||||||
fi
|
fi
|
||||||
|
warn_timeout=`date --date='1 minutes' +%s`
|
||||||
|
|
||||||
|
|
||||||
checked=false
|
checked=false
|
||||||
until [ "${checked}" = "" ]; do
|
until [ "${checked}" = "" ]; do
|
||||||
@@ -459,9 +461,11 @@ STATUS(){
|
|||||||
else
|
else
|
||||||
ssh -q root@${nip} [[ -f ${REPL_CHECKS[${rcheck}]}/test.repl ]] && checked="`${PH_CMD} \"ssh root@${nip} \"cat ${REPL_CHECKS[${rcheck}]}/test.repl\" | diff - ${REPL_CHECKS[${rcheck}]}/test.repl\"`"
|
ssh -q root@${nip} [[ -f ${REPL_CHECKS[${rcheck}]}/test.repl ]] && checked="`${PH_CMD} \"ssh root@${nip} \"cat ${REPL_CHECKS[${rcheck}]}/test.repl\" | diff - ${REPL_CHECKS[${rcheck}]}/test.repl\"`"
|
||||||
fi
|
fi
|
||||||
if [ "`date +%s`" -gt "$timeout" ]; then
|
if [ "`date +%s`" -gt "${timeout}" ]; then
|
||||||
timeout=true
|
timeout=true
|
||||||
break
|
break
|
||||||
|
elif [ "`date +%s`" -gt "${warn_timeout}" ]; then
|
||||||
|
echo -en " waiting for sync... "
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
if [ "${timeout}" = "true" ]; then
|
if [ "${timeout}" = "true" ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user