Update nodemgmt-scripts.sh
This commit is contained in:
@@ -880,6 +880,7 @@ GUI(){
|
|||||||
STATUS freespace ${3}
|
STATUS freespace ${3}
|
||||||
else
|
else
|
||||||
STATUSRUNS=($(find ${NM_TMPFOLDER}/* -maxdepth 1 -type d -iname "status-*" 2>/dev/null))
|
STATUSRUNS=($(find ${NM_TMPFOLDER}/* -maxdepth 1 -type d -iname "status-*" 2>/dev/null))
|
||||||
|
echo "HERE: ${STATUSRUNS}"
|
||||||
if [ ${STATUSRUNS} -le 3 ]; then
|
if [ ${STATUSRUNS} -le 3 ]; then
|
||||||
STATUS_START=$(date +%Y-%m-%d-%H-%M-%S)
|
STATUS_START=$(date +%Y-%m-%d-%H-%M-%S)
|
||||||
STATUSRUN_TMPFOLDER="${NM_TMPFOLDER}/status-${STATUS_START}"
|
STATUSRUN_TMPFOLDER="${NM_TMPFOLDER}/status-${STATUS_START}"
|
||||||
@@ -926,7 +927,7 @@ GUI(){
|
|||||||
${NM_SCRIPT} status ${2} ${3} ${4}
|
${NM_SCRIPT} status ${2} ${3} ${4}
|
||||||
exit 0
|
exit 0
|
||||||
else
|
else
|
||||||
if [ ! -f ${NM_TMPFOLDER}/.statusclean ] || [ $(expr $(date +%s) - $(stat -c %Y ${NM_TMPFOLDER}/.overload)) -ge 600 ]; then
|
if [ ! -f ${NM_TMPFOLDER}/.overload ] || [ $(expr $(date +%s) - $(stat -c %Y ${NM_TMPFOLDER}/.overload)) -ge 600 ]; then
|
||||||
SENDNOTICE "NODEMGMT OVERLOAD" "Whooooaaaaa there cowboy, we got 3 threads running already.... easy killer!" 1
|
SENDNOTICE "NODEMGMT OVERLOAD" "Whooooaaaaa there cowboy, we got 3 threads running already.... easy killer!" 1
|
||||||
touch ${NM_TMPFOLDER}/.overload
|
touch ${NM_TMPFOLDER}/.overload
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user