Re: Set up PPP for two ISPs
gli <gli@interlog.com> writes:
> I am using Debian 1.2. I set up my box to connect to an ISP using PPP, I
> invoke the connection by the script pon, it all work out fine. Now I want
> to join another ISP. How do I set up my box, to connect to two ISP, one
> at a time? Please help.
What I did was use this script as /usr/local/bin/pon
#!/bin/sh
if [ $# = 0 ] ; then
CHAT=/etc/ppp.chatscript
elif [ $# = 1 ] ; then
CHAT=/etc/ppp.chat.$1
else
echo usage: pon [destination]
exit 1
fi
if [ ! -r $CHAT ] ; then
echo pon: can not read $CHAT
exit 1
fi
if [ -r /etc/ppp.options_out ]; then
/usr/sbin/pppd connect "/usr/sbin/chat -v -f $CHAT" `cat /etc/ppp.options_out`
else
echo "You do not have permissions to access /etc/ppp.options_out"
fi
exit 0
where /usr/local/bin/ comes before /usr/bin/ in my path. I then
made an /etc/ppp.chatscript file for every ISP I wish to connect to:
compute root: ls -lta /etc/ppp.chat*
lrwxrwxrwx 1 root root 18 Dec 31 10:20 /etc/ppp.chatscript -> ppp.chat.softsound
-rw-r--r-- 1 root root 169 Dec 26 22:11 /etc/ppp.chat.softsound
-rw-r--r-- 1 root root 167 Dec 4 07:44 /etc/ppp.chat.demon
-rw-r--r-- 1 root root 169 Nov 27 18:19 /etc/ppp.chat.magpie
[ N.B. I abbreviated chatscript to chat for readability ].
/etc/ppp.chatscript is a symbolic link to the default, and if you supply
an argument to pon it uses that script instead. This works because non
of the files in /etc/ppp/ are ISP specific. It works fine for me.
I'm told (by the maintainers) that the next version of ppp will have
it's own solution.
Tony Robinson
--
http://www.SoftSound.demon.co.uk/
email ajr@softsound.com
Fax +44-1223-562588
--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-user-REQUEST@lists.debian.org . Trouble? e-mail to Bruce@Pixar.com
Reply to: