Subject: Re: Problems making my machine a gateway.
To: David Hobley <davidh@wr.com.au>
From: Rob Windsor <windsor@warthog.com>
List: netbsd-users
Date: 03/24/1998 10:17:01
Verily did David Hobley write:

> I am trying to make my machine a gateway. I have a desktop PC which runs
> NetBSD and a Windows 95 Libretto. I would like to set things up so that
> when the desktop machine machine dials up it can provide the libretto a
> means of accessing the internet via my ethernet.

> I have compiled the kernel to have the GATEWAY option and set up the
> libretto to point to the desktop as a gateway. But it doesn't work. I am
> totally stumped.

Can you explain details on "it doesn't work"?  Can you run traceroute or ping
from the libretto to something on the outside world?  Can you ping the
ppp interface's ip address from libretto (in your following example, it would
be dialup05.wr.com.au).

Also, can ishtar ping something else other than hosts at 203.12.42.x?

> ishtar% netstat -r
> Routing tables

> Internet:
> Destination     Gateway            Flags     Refs     Use    Mtu  Interface
> default         cs1wr.wr.com.au    UG          4    11139      -  ppp0
> localhost       localhost          UH          1     1372      -  lo0
> 192.168.42      link#1             UC          0        0      -  ne1
> ishtar          00:40:33:25:06:51  UHL         0    97207      -  lo0
> sharpblue       00:c0:f0:1c:60:88  UHL         0        5      -  ne1
> cs1wr.wr.com.au dialup05.wr.com.au UH          1        0      -  ppp0

This looks normal, I would assume that you double-checked the default route
that ppp set.

> sharpblue is the libretto and running tracert on that gets to ishtar
> (the desktop), but gets no further. If I ping a host I get:

> ishtar% ping proxy.wr.com.au
> PING proxy.wr.com.au (203.12.42.24): 56 data bytes
> 64 bytes from 203.12.42.24: icmp_seq=0 ttl=63 time=2935.719 ms
> 64 bytes from 203.12.42.24: icmp_seq=1 ttl=63 time=1952.220 ms
> ^C64 bytes from 203.12.42.24: icmp_seq=2 ttl=63 time=1960.783 ms
> 64 bytes from 203.12.42.24: icmp_seq=3 ttl=63 time=2550.094 ms

> ----proxy.wr.com.au PING Statistics----
> 4 packets transmitted, 4 packets received, 0% packet loss
> round-trip min/avg/max = 1952.220/2349.704/2935.719 ms

> Interestingly enough, traceroute doesn't work, even though ping does:

> ishtar% traceroute proxy.wr.com.au
> traceroute: Warning: Multiple interfaces found; using 192.168.42.1 @ ne1
> traceroute to proxy.wr.com.au (203.12.42.24), 30 hops max, 40 byte packets
>  1  * * *
>  2  * * *
> ...

Nah, something is broken in traceroute, it doesn't pay attention to the
routing table in the kernel, and just picks an arbitrary interface to
use.

I don't know when it started doing this, but I've recently discovered it
also.  IMNSO, it's a bug.

Use the -i option to specify an interface, in your case, use "-i ne0"

-- Rob
----------------------------------------
Internet: windsor@warthog.com
Life: Rob@Carrollton.Texas.USA.Earth

The weather is here, wish you were beautiful.