>
>The best is to use peer IP, if this IP isn't pingable i think no one could
>be :-)
>
>PEER_IP=`/sbin/ifconfig | grep P-t-P | cut -d ':' -f 3 | cut -d ' ' -f 1`
>
>then just #ping $PEER_IP
The use of the peer IP is a good idea, but your script only work when you
have only *ONE* interface using P-t-P. In the case of you use a GRE tunnel
or a VPN, this command return an IP adress each time it find one.
I have had this problem so I have made this command :
TEST_ADDR=`ifconfig | awk '{ /^ppp0/ && A=FNR; if (FNR == A+1) VAL=$0 }
END { $0=VAL; print $3 }' | grep "P-t-P" | cut -d":" -f2`
This command return the peer address only for the interface ppp0
Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se d�sinscrire : mailto:[EMAIL PROTECTED]?subject=unsubscribe