| Jak najbardziej się da to zrobić. Odpowiedni skrypt + cron i powinno działać :) 
 Znalezione na necie, nie moje, wypróbuj :)
 
 
 1. Polecam temat w całości poświęcony funkcji watchdog: "Custom Tomato script" @ www.linksysinfo.org
 
 [url]
 http://www.linksysinfo.org/forums/showthread.php?t=51203
 [/url]
 
 ---------------------------------------------------------------
 
 2. Następny skrypcik, tylko trochę trzeba go przerobić :)
 
 Here is a small script that can monitor networking:
 
 
 
 #!/bin/sh
 
 # monitorscript.sh - monitor the network
 
 PATH=/bin:/usr/bin:/usr/local/bin
 export PATH
 
 # your _own_ IP addr or hostname
 hostn="linuxbox.your.supercomputer"
 
 if ping -w 5 -qn -c 1 $hostn > /dev/null ; then
 # ok host is up
 echo "0" > /etc/pingfail
 else
 # no answer count up the ping failures
 if [ -r /etc/pingfail ] then
 pingfail=`cat /etc/pingfail`
 else
 # we do not handle the case where the
 # pingfail file is missing
 exit 0
 fi
 pingfail=`expr "$pingfail" "+" 1`
 echo "$pingfail ping failures"
 echo "$pingfail" > /etc/pingfail
 if [ $pingfail -gt 10 ] then
 echo "More than 10 ping failures. System reboot..."
 /sbin/shutdown -t2 -r now
 fi
 fi
 
 # end of monitor script
 
 You can combine this with a crontab entry that will run the script every 15 minutes:
 
 
 
 1,15,30,45 * * * * /path_to_the_script/monitorscript.sh
 
Edytowany przez wav-e dnia 02-07-2008 14:40
 
 Pozdrawiam,WavE
 ---------------
 ISP WiFi 5GHz >><< Ovislink AirLive WLA-5200AP <---> Linksys WRT54GL v1.1 + Tomato v1.19 PL >><< Kompy
 ...i wszystko ?miga :-)
 |