NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: default gateway on different subnet

Petar Bogdanovic wrote:

what is the proper NetBSD equivalent for the following two linux
route-commands in a situation where one host has not just one network
interface but also the problem that the default gateway is not on his

   ifconfig eth0 netmask

   route add -net netmask dev eth0
   route add default gw

How is that supposed to work? Is it to just broadcast on eth0 whenever it wants to reach, or is eth0 actually both and, or is some other magic interpretation the way to look at this?

This setup looks very broken. I'm surprised that Linux would allow it.

Looking at the routing table you provided, it appears as if Linux actually pretends that eth0 are on both networks. So what you should do is setup the interface with both addresses, so that it actually knows that it's on both networks.


Home | Main Index | Thread Index | Old Index