>>do
>> # testing the connection ....
>> ping -c10 $ping_host > /dev/null 2>&1
>>
>> if [ $? -gt 0 ]; then # not connected ...
>> # logs
>> date >> $log_file
>> # cleaning
>> /bin/killall pppd 2&>/dev/null
>> /bin/rm -f /var/run/ppp*.pid 2&>/dev/null
>> /etc/rc.d/nice.sh 2&>/dev/null # firewall down
>> sleep 3
>> # reconnection
>> pppd call adsl # dialing
>> sleep 30
>> /etc/rc.d/fw.sh 2&>/dev/null # firewall up
>> fi
>> # the test is done every 30 seconds
>> sleep 30
>>done
>># faudrait pas en arriver la ...
>>exit 1
>>_______________________________________________________________________
>>
> What a superb little code snippet! In the UK BT seems to disconnect
> you 3 or 4 times a day. This saves me loads of grief. Thanks.
Umm. The only thing I find a little disconcerting is deleteing the .pid
file (which after all should be cleaned up by pppd closing down properly).
Does your BT OW go down that often. I typically run for 3-7 days without a
hitch.
Alex.
Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se d�sinscrire : mailto:[EMAIL PROTECTED]?subject=unsubscribe