DragonFlyBSD not in compliance with RFC 1122

sam samwun at hgcbroadband.com
Fri Mar 18 05:38:29 PST 2005


Jeffrey Hsu wrote:
Gary Allan wrote:

Hello,

I ran into a problem today. I administer a machine that needs to sit 
on two separate networks 192.168.2.2/24 and 192.168.15.2/24. The 
network card is configured as:

xl0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> mtu 1500
        inet 192.168.15.2 netmask 0xffffff00 broadcast 192.168.15.255
        inet 192.168.2.2 netmask 0xffffff00 broadcast 192.168.2.255
        ether 00:10:5a:f7:6e:71
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active
The machine has a default route of 192.168.15.1.
(Public IP addresses replaced with private.)
All is well except that 192.168.2.2 is inaccessible from the Internet. 
A quick RTFM reveals that I need to add a second default gateway

I've resolved this by using IPFW to forward the necessary traffic from 
192.168.2.0/24 to the 192.168.2.1 router but feel this is a bit of a 
bodge. I've noticed recent routing code commits so I'm hoping this is 
a good time


Can't you just add
 route add 192.168.2/24 192.168.2.1
this should work. I use this static route from internet to the internal 
LAN which located behind the second freebsd gateway.

Sam.





More information about the Users mailing list