Update nodemgmt-scripts.sh
This commit is contained in:
@@ -786,6 +786,15 @@ GUI(){
|
||||
DOWNLIST ${2}
|
||||
fi;;
|
||||
status)
|
||||
if [ -f "${NM_FOLDER}/status-check.running" ] && [ $(expr `date +%s` - $(stat -c %Y ${NM_FOLDER}/status-check.running)) -gt 1800 ]; then
|
||||
SENDNOTICE "Nodemgmt Script Error" "Status monitoring system resetting"
|
||||
mv ${NM_FOLDER}/status-check.running ${NM_FOLDER}/status-check.running.crash
|
||||
getStuckNM=$(pgrep -f '/nodemgmt')
|
||||
for i in $getStuckNM; do
|
||||
/bin/kill $i
|
||||
done
|
||||
fi
|
||||
|
||||
if [ -f "${NM_FOLDER}/status-check.running" ]; then
|
||||
cbd=`date +%s`-$(stat -c %Y ${NM_FOLDER}/status-check.running)
|
||||
[ ${cbd} -gt 900 ] && rm -f "${NM_FOLDER}/status-check.running"
|
||||
|
||||
Reference in New Issue
Block a user