Re: default route (back again)


Subject: Re: default route (back again)
From: Peter Q. Olsson (olsson@koyukuk.at.uaa.alaska.edu)
Date: Mon Mar 10 2003 - 16:40:28 AKST


Arthur and all-

I am dredging this back up from the "unfinished e-mail ashes". I started
composing this response (at work) but could not address the issue (with home
network) well. Done a bit of testing and now am in a better position to respond
to arthur's reply (below)

 ************ MY ORIGINAL POSTING:

 I have a rather naive question regarding routing.

My home network is connected by ethernet. I occasionally connect to the outer
world via kppp, over the phone using UAA as my ISP. Currently, I have to bring
my ethernet interface down so that traffic goes through the ppp interface. Is
there some simple way that I can have both the ppp and ethernet interfaces both
up at the same time, so that, for example I can print a web page on my network
printer while browsing via the ppp interface. I am sure this is not rocket
science...

I should also note that after I no longer have a ppp connection and do an
i"fconfig eth1 up", I still cannot see my local network (again). I have to
restart th3e network (via init.d script) to get my local connectivity back.

**************** ARTHUR'S REPLY (DISSECTED BY MY COMMENTS)

>I'm not sure why you're doing what you are. If you only have one local subnet
>for the home network, you should only have a route to that network (not
>0.0.0.0). When you're resolving local hosts it should still see the LAN as
>the lowest cost route and go to it directly, while internet addresses would go
>over the ppp connection.

That is what I would have expected as well.

> Having to drop the local interface just to browse
>the internet is bizarre.

yup.

>If I had to hazard a guess, your problem is likely not routing, but DNS. Are
>you running a DNS server for the LAN on another box? If so, the ppp
>connection is probably rewriting your /etc/resolv.conf, making your LAN
>addresses unresolvable.

All the addresses on the local network are to be found in /etc/hosts (in a
192.168.10 space) Things are set up so that the hosts table is consulted first.
Resolving local addresses is not the issue. It IS true that ppp adds a couple of
addresses in /etc/resolv.conf (yes, literally adds them with a comment after each
about how these are temporary additions).

It is also true that the problem involves DNS. In particular, the machine tries
to contact the DNS servers (none of which is on the local network) through the
LAN ethernet interface. If I bring down eth1 b4 I establish the ppp connection,
everything works just as one would suspect. I have thus reasoned, perhaps
incorrectly, that I have a routing problem and that the ppp interface is not
getting to be the default route...?

> Ideally, you'd want your DNS settings to remain on
>the LAN server and have it act as a caching server for internet addresses.
>This would require setting up your ppp box as a PNAT box, though, for the DNS
>server.
>
>Can you verify any of this?
>

PLZ find below some screen captures, interspersed w/ my comments, which may best
explain the problem:

### start with both ppp0 and wth1 up and running...

[root@iliamna etc]# more /etc/resolv.conf
nameserver 137.229.141.15
nameserver 137.229.141.25
nameserver 137.229.99.99
nameserver 137.229.10.39 #kppp temp entry
nameserver 137.229.12.41 #kppp temp entry

### the comments in resolv.conf are put there by kppp

[root@iliamna etc]# ping 137.229.141.15
PING 137.229.141.15 (137.229.141.15) from 192.168.10.20 : 56(84) bytes of data.
From 192.168.10.20 icmp_seq=1 Destination Host Unreachable
From 192.168.10.20 icmp_seq=2 Destination Host Unreachable
From 192.168.10.20 icmp_seq=3 Destination Host Unreachable

[root@iliamna etc]# ifconfig eth1 down
[root@iliamna etc]# ifconfig
lo Link encap:Local Loopback
          inet addr:127.0.0.1 Mask:255.0.0.0
          UP LOOPBACK RUNNING MTU:16436 Metric:1
          RX packets:601 errors:0 dropped:0 overruns:0 frame:0
          TX packets:601 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:178387 (174.2 Kb) TX bytes:178387 (174.2 Kb)

ppp0 Link encap:Point-to-Point Protocol
          inet addr:137.229.98.42 P-t-P:137.229.98.33 Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1
          RX packets:5 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:3
          RX bytes:3066 (2.9 Kb) TX bytes:84 (84.0 b)

[root@iliamna etc]# ping 137.229.141.15
connect: Network is unreachable

########### kill ppp process

[1]+ Done kppp

[root@iliamna etc]# ifconfig eth1 down
{root@iliamna etc]# kppp &
[1] 27634

############## establish ppp connection via terminal-based gui login

[root@iliamna etc]# ifconfig
lo Link encap:Local Loopback
          inet addr:127.0.0.1 Mask:255.0.0.0
          UP LOOPBACK RUNNING MTU:16436 Metric:1
          RX packets:601 errors:0 dropped:0 overruns:0 frame:0
          TX packets:601 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:178387 (174.2 Kb) TX bytes:178387 (174.2 Kb)

ppp0 Link encap:Point-to-Point Protocol
          inet addr:137.229.98.36 P-t-P:137.229.98.33 Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1500 Metric:1
          RX packets:4 errors:0 dropped:0 overruns:0 frame:0
          TX packets:5 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:3
          RX bytes:149 (149.0 b) TX bytes:124 (124.0 b)

[root@iliamna etc]# ping 137.229.141.15
PING 137.229.141.15 (137.229.141.15) from 137.229.98.36 : 56(84) bytes of data.
64 bytes from 137.229.141.15: icmp_seq=1 ttl=125 time=263 ms
64 bytes from 137.229.141.15: icmp_seq=2 ttl=125 time=195 ms

############ note that now, the ping comes from 137.229.98.36, not 192.168.10.20.

PQO

    __________________________________________________________________
   | |
   | Dr. Peter Q. Olsson, |
   | Chief Scientist, Alaska Experimental Forecast Facility |
   | University of Alaska Anchorage |
   | 2811 Merrill Field Drive |
   | Anchorage, AK 99501 |
   | voice: (907) 264-7449 |
   | fax : (907) 264-7444 |
   | olsson@aeff.at.uaa.alaska.edu |
   |__________________________________________________________________|

---------
To unsubscribe, send email to <aklug-request@aklug.org>
with 'unsubscribe' in the message body.



This archive was generated by hypermail 2a23 : Mon Mar 10 2003 - 16:43:28 AKST