Update status.inc
This commit is contained in:
@@ -228,6 +228,13 @@ STATUS(){
|
||||
|
||||
for NTYPE in "${ntypesel[@]}"; do
|
||||
PH=${NTYPE}_HOSTS[0]
|
||||
if [ -f ${NM_TMPFOLDER}/${!PH}.disable ] || [ -f ${NM_TMPFOLDER}/${!PH}.down ] || [ -f ${NM_TMPFOLDER}/${!PH}.skip ]; then
|
||||
if [ $(eval echo \${#${PHA}[@]}) -eq 2 ]; then
|
||||
skip=1
|
||||
else
|
||||
PH=${NODETYPE}_HOSTS[1]
|
||||
fi
|
||||
fi
|
||||
PH_CMD="ssh -q -o ConnectTimeout=3 -o ConnectionAttempts=1 root@${!PH}"
|
||||
var=${NTYPE}_REPL_CHECK[@]
|
||||
if [ ! -z ${!var+x} ]; then
|
||||
@@ -257,7 +264,7 @@ STATUS(){
|
||||
checked=good
|
||||
elif [ -f ${STATUSRUN_TMPFOLDER}/repl.${rcheck}.${nip}.timeout ]; then
|
||||
checked=timeout
|
||||
elif [ -f ${STATUSRUN_TMPFOLDER}/repl.${rcheck}.${nip}.skip ] || [ -f ${STATUSRUN_TMPFOLDER}/repl.${nip}.skip ]; then
|
||||
elif [ ${skip} -eq 1 ] || [ -f ${STATUSRUN_TMPFOLDER}/repl.${rcheck}.${nip}.skip ] || [ -f ${STATUSRUN_TMPFOLDER}/repl.${nip}.skip ] || [ -f ${STATUSRUN_TMPFOLDER}/repl.${!PH}.skip ]; then
|
||||
checked=skip
|
||||
fi
|
||||
if [ $(($(date +%s)-scanstart)) -gt 600 ]; then
|
||||
@@ -916,7 +923,7 @@ REPLSTART(){
|
||||
PH=${NODETYPE}_HOSTS[0]
|
||||
PHA=${NODETYPE}_HOSTS
|
||||
skip=0
|
||||
echo "HERE1: ${skip} - ${!PH}"
|
||||
# echo "HERE1: ${skip} - ${!PH}"
|
||||
if [ -f ${NM_TMPFOLDER}/${!PH}.disable ] || [ -f ${NM_TMPFOLDER}/${!PH}.down ]; then
|
||||
touch ${STATUSRUN_TMPFOLDER}/repl.${!PH}.skip
|
||||
if [ $(eval echo \${#${PHA}[@]}) -eq 2 ]; then
|
||||
@@ -929,10 +936,10 @@ REPLSTART(){
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
echo "HERE2: ${skip} - ${!PH}"
|
||||
# echo "HERE2: ${skip} - ${!PH}"
|
||||
|
||||
if [ ${skip} -eq 0 ] && [ "${!PH}" != "" ]; then
|
||||
echo "not skipped"
|
||||
# echo "not skipped"
|
||||
PH_CMD="ssh -q -o ConnectTimeout=3 -o ConnectionAttempts=1 root@${!PH}"
|
||||
var=${NODETYPE}_REPL_CHECK[@]
|
||||
if [ ! -z ${!var+x} ]; then
|
||||
@@ -943,8 +950,8 @@ REPLSTART(){
|
||||
${PH_CMD} 'find '${NM_REPL_CHECK_LOC[${rcheck}]}' -iname "*.sync-conflict-*" -exec rm {} \;' &
|
||||
done
|
||||
fi
|
||||
else
|
||||
echo "skipped"
|
||||
# else
|
||||
# echo "skipped"
|
||||
fi
|
||||
echo
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user