as you correctly suggest, i don't really need a waiting interval. what i really need is to ping a list of hosts every minute or so (the polling interval). if ping returns an error, then i have to check if other hosts are unreachable. i don't have to wait to do this check though.
if i cannot reach those hosts, i can safely assume that i am offline and need to restart my network. if of course google, redhat and ibiblio are down at the same time, i can still be online, but this possibility is slight. maybe my modem requires some "rest period" and locks up if network is restartet too often. but then maybe not. some testing is required and in the worst case i will be wiring relays to the serial port :-) so i will rewrite my script to do the above mentioned. in case someone is interested, i can publish the result to the list. regards, kiril -----Urspr�ngliche Nachricht----- Von: Erich Titl <[EMAIL PROTECTED]> An: Kiril <[EMAIL PROTECTED]> Datum: Freitag, 31. Mai 2002 09:42 Betreff: Re: [leaf-user] Detecting Disconnected Network Hi Kiril At 22:39 30.05.2002 +0200, you wrote: >hi erich > >your version has the advantage that the hosts are rotated, so i can poll >much faster. initially i just wanted to ping one host and keep the others as >a reserve in case the first went offline. however this delays recovery, as >the following log shows: 8 minutes before network was up again. In your version you jump from one host to the other as soon as one host is offline. This does not mean that _YOU_ are offline, it only means that you cannot ping that particular host. And then as soon as you have used up your host list, you reboot anyway, although you may perfectly well be online. Use a short interval, even no interval at all... >so this brings up the next question, which is how to find reasonable delays >before restarting the network and waiting for the network to go up before >restarting it again. You can always use more reference hosts and short delays, until you find you are reasonably satisfied with the result. It might even be sufficient to just poll your default gateway if it replies to pings. regards >thanks to all, > >kiril > >[root@bay network]# cat current | tai64nlocal >2002-05-28 18:59:03.520783500 starting connection monitor... >2002-05-30 15:15:34.888502500 www.bol.de is down, trying next host... >2002-05-30 15:17:34.918443500 www.db24.de is down, trying next host... >2002-05-30 15:19:34.948508500 www.redhat.com is down, trying next host... >2002-05-30 15:21:34.978430500 www.linux.org is down, trying next host... >2002-05-30 15:23:35.008522500 www.ibiblio.org is down, trying next host... >2002-05-30 15:23:35.029444500 network is down. restarting... >2002-05-30 15:23:36.652992500 Setting network parameters: [ OK ] >2002-05-30 15:23:36.851080500 Bringing up interface lo: [ OK ] >2002-05-30 15:23:37.756420500 Bringing up interface eth0: [ OK ] >2002-05-30 15:24:43.112993500 starting connection monitor... Erich THINK P�ntenstrasse 39 8143 Stallikon mailto:[EMAIL PROTECTED] PGP Fingerprint: BC9A 25BC 3954 3BC8 C024 8D8A B7D4 FF9D 05B8 0A16 _______________________________________________________________ Don't miss the 2002 Sprint PCS Application Developer's Conference August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm ------------------------------------------------------------------------ leaf-user mailing list: [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/leaf-user SR FAQ: http://leaf-project.org/pub/doc/docmanager/docid_1891.html
