Subject: default gateway "unreachable"
To: None <tech-net@netbsd.org>
From: Hans Bulfone <jsb@nil.at>
List: tech-net
Date: 03/11/1999 19:01:35
Hi!

I'm relatively new to *BSD (but have previously used Linux on i386 and alpha)
and have a question about routing:

 -----------+------------ LAN: a.a.a.56/29
            |
            | a.a.a.57
         NetBSD/alpha box
            | a.a.a.61
            |
            .
            . ethernet bridge
            .
            | b.b.b.17
        Linux router (my default gateway)

I know that's not very well designed, the NetBSD box should have
a b.b.b.x address on it's outer interface, but at the moment I have
to live with this.

Now I want to set the default gateway on the NetBSD box.

route add -iface -host b.b.b.17 a.a.a.61
route add default b.b.b.17
Here I get an error saying that the network is unreachable. He is right
because the interface has no ip address in the b.b.b.x net.
I've tried using -ifa and -ifp to select the interface, but with no luck.
I studied the /sys/net/route.c and /sys/net/rtsock.c files and found out
that -ifa and -ifp are not relevent in the decision if the network is
reachable or not because they are not passed to the ifa_ifwithroute
function.

Have I missed something or is such a setup impossible ?

(I'm running NetBSD 1.3I)
Thanks in advance for your help.

cu hans.

-- 
Hans Bulfone, at-net <jsb@nil.at> (HB1818-RIPE)
~
~
:wq