Displaying 1 result from an estimated 1 matches for "waitinit".
2014 Sep 03
2
howto force shutdown if nut-snmp Communications lost
...be information only. (s. below)
Any suggestions?
The last way would be a ugly cronjob (like: ping || shutdown).
regards Heiko
------------------------------------------------------
- script simulate network failure
defaultrouter=`netstat -rn | grep "^0.0" | awk '{print $2}'`
waitinit=10
waitdownup=600
syslog=/var/log/syslog
eth=eth0
echo "defaultrouter=$defaultrouter syslog=$syslog eth=$eth waitinit=$waitinit waitdownup=$waitdownup"
(sleep $waitinit;
echo "`date +%m\ %d\ %H:%M:%S` exec ifconfig $eth down"; ifconfig $eth down;
echo "`date +%m\ %d\ %H:%M:...