Witam ja używam czegoś takiego i narazie działa
Cytuj:
#!/bin/bash
# source application-specific settings
. /etc/rc.conf
. /etc/rc.d/functions
HOST=www.onet.pl
case "$1" in
start)
stat_busy "Uruchamiam połączenie z internetem "
[ -x /etc/network/external/rc.$CONNECTION ] && /etc/network/external/rc.$CONNECTION start
if [ $? -gt 0 ]; then
stat_fail
else
stat_done
fi
;;
stop)
stat_busy "Zatrzymuję połączenie z internetem "
[ -x /etc/network/external/rc.$CONNECTION ] && /etc/network/external/rc.$CONNECTION stop
if [ $? -gt 0 ]; then
stat_fail
else
stat_done
fi
killall pppd
;;
restart)
$0 stop
sleep 15
$0 start
;;
*)
echo "Użycie: $0 {start|stop|restart}"
esac
exit 0