ppp default route - not setting...

ppp default route - not setting...

Post by Bruce P. Kli » Sat, 14 Oct 1995 04:00:00



Hello Fellow Linuxians:

Thanks to the help I have been getting from you all
I am slowly but surely getting my machine to work
bit by bit, and the latest nuisance is my ppp routing.

I have 2 machines at home, networked together with
ethernet.  Modems on both but only one phone line.
I connect to the Internet via an ISP, so I setup
my valid IP address on whatever machine is calling
out.  I do not route the other machine because it
is behind the ppp connection because they do not
have valid IP numbers.

I have ppp setup as follows.  First the chat script and
then the pppd command:

CHATSCRIPT (invoked by the pppscript below with
the "connect" directive, the "chat" command uses
this "chat script" to dial the number, log in and
then hand off to pppd):
---------------------------------------------------------
'' <modem_reset_string> OK ATDT<phone#> CONNECT '' ogin: <id> word: <pw>

The connection actually works solidly!
I didn't really need to include it here, but thought maybe others
who haven't set this up should see how easy it is!

PPPD COMMAND (run in a script):
-------------------------------
/usr/lib/ppp/pppd                                     \
debug                                                 \
connect "/usr/lib/ppp/chat -v -f /local/chatscript"   \
/dev/cua1                                             \
38400                                                 \
crtscts                                               \
modem                                                 \
defaultroute                                          \
mtu 1500                                              \
netmask 255.255.255.0                                 \
<mydomain_name>

The above script is "supposed" to start ppp in debug mode,
configure the netmask and IP address, and add a default
route pointing to the ppp interface while it is up!

Here is what I get in the syslog:
--------------------------------
Oct 12 18:49:37 iggy pppd[206]:\
        could not set up connection
Oct 12 18:50:15 iggy pppd[263]: \
        ppp not replacing existing default route to eth0[

Despite what syslog says, the connection does start
and I can reach  the machine at the other end of the
link.  When this fails i do a "route add default ppp0" and
then the route is installed and I can query the DNS server
and telnet out, in other words - routing starts working.

What is stranger is that when the ppp connection is
broken the route goes back to the ethernet, and then
the next time I connect via ppp - the default route
now gets installed!

Does anyone know why this is happening and can give
me a fix, or change I can make to stop having to
manually add that route the first time I connect?

Thanks for any ideas.

Brucek

 
 
 

1. pppd not setting up default route in routing table

Hi,

I'm trying to get my Redhat Linux 5.2 machine to talk to the internet.
Eventually, I want to use it as a gateway for my home network which will
have a couple of Win98 machines.

I used the Linux tools to set up the modem and network stuff.  When I
activate the ppp0 interface, I get a good connection to my ISP.  I can ping
the remote host that is listed in /var/log/messages, but I can't get beyond
that machine.

When I look at the routing table using 'route -nr', I see that a default
route hasn't been set up.  If I check the pppd process, I see that pppd was
started with the defaultroute argument.  My assumption is that the lack of a
default route is causing my problem, but I don't know how to fix it.  I've
tried adding the route manually with 'route add ipaddress default', but that
doesn't work.

I'm at a loss as to what to try next.
You can reply directly to me using email by deleting the .nospam from my
email address.

Thanks,
  Ray

2. Searching for a searching tool that really works!!

3. Stupid question - How do i set ppp to default route.

4. suid on one script does not allow read of another

5. Two interfaces: Set default default route?

6. Diamond FireGL 1000 Pro

7. Default Route always sets default interface

8. Scripts for adding users - does anyone know 'sam'?

9. User PPP not adding default route

10. PPP not replacing default route to sl0[0.0.0.0]

11. diald did not set default route

12. RH6.2 default route not set at boot time

13. ppp redhat 5.1: not replacing default route eth0: MEANING ???