This commit is contained in:
2023-12-06 09:06:46 -06:00
parent 2b391900b2
commit 69a35755c4
2 changed files with 18 additions and 17 deletions

View File

@@ -764,6 +764,23 @@ REPLCHECK(){
[ "${timeout}" == "true" ] && touch ${NM_TMPFOLDER}/repl.${rcheck}.${nip}.timeout || touch ${NM_TMPFOLDER}/repl.${rcheck}.${nip}.good
}
REPLSTART(){
NODETYPE=${1}
PH=${NODETYPE}_HOSTS[0]
if [ ! -f ${NM_FOLDER}/${!PH}.down ]; then
PH_CMD="ssh root@${!PH}"
var=${NODETYPE}_REPL_CHECK[@]
if [ ! -z ${!var+x} ]; then
for rcheck in "${!var}"; do
${PH_CMD} rm -f ${NM_FOLDER}/test.repl
daterun=`date +%Y-%m-%d-%H-%M-%S`
${PH_CMD} "echo -e \"Replcation-Test\n${daterun}\" > ${NM_REPL_CHECK_LOC[${rcheck}]}/test.repl" &
${PH_CMD} 'find ${NM_REPL_CHECK_LOC[${rcheck}]} -iname "*.sync-conflict-*" -exec rm {} \;' &
done
fi
fi
}
STATUS_SCANTIMES(){
scandefault=200
while [ $# -gt 0 ]; do