Fixed MINIMUM_SPACE=0 should not check space requirements, Thanks Val

pull/184/head
deajan 4 years ago
parent a9cb30ffb4
commit eaeb218508

@ -7,7 +7,7 @@ PROGRAM="osync" # Rsync based two way sync engine with fault tolerance
AUTHOR="(C) 2013-2020 by Orsiris de Jong"
CONTACT="http://www.netpower.fr/osync - ozy@netpower.fr"
PROGRAM_VERSION=1.3.0-prerc1
PROGRAM_BUILD=2019122406
PROGRAM_BUILD=2020012301
IS_STABLE=false
CONFIG_FILE_REVISION_REQUIRED=1.3.0
@ -284,6 +284,7 @@ function _CheckReplicasLocal {
return 1
fi
if [ $MINIMUM_SPACE -ne 0 ]; then
Logger "Checking minimum disk space in local replica [$replicaPath]." "NOTICE"
diskSpace=$($DF_CMD "$replicaPath" | tail -1 | awk '{print $4}')
retval=$?
@ -299,6 +300,8 @@ function _CheckReplicasLocal {
Logger "There is not enough free space on local replica [$replicaPath] ($diskSpace KB)." "WARN"
fi
fi
fi
return $retval
}
function _CheckReplicasRemote {
@ -349,6 +352,7 @@ function _CheckReplicasRemoteSub {
exit 1
fi
if [ $MINIMUM_SPACE -ne 0 ]; then
RemoteLogger "Checking minimum disk space in remote replica [$replicaPath]." "NOTICE"
diskSpace=$($DF_CMD "$replicaPath" | tail -1 | awk '{print $4}')
retval=$?
@ -364,6 +368,7 @@ function _CheckReplicasRemoteSub {
RemoteLogger "There is not enough free space on remote replica [$replicaPath] ($diskSpace KB)." "WARN"
fi
fi
fi
return $retval
}
_CheckReplicasRemoteSub

Loading…
Cancel
Save