Wolfgang Riegler wolfgang.riegler at
Wed Sep 15 19:23:07 UTC 2010


I have a question about building a FreeBSD gateway.

I want to create a subnet in our internal company network. I have installed FreeBSD 8.0 RELEASE i386, no updates, right from the FreeBSD CD. Now I want to configure this box as the gateway of the subnet. I have two NICs configured. One external for the company network and one for the new subnet. On this box I can reach any other computer in our internal network, I have internet access, too, and I can reach the box on the subnet. The box on the subnet is able to ping both NICs on my FreeBSD box, but cannot reach any other computer of my company network or the internet. Because I don't need any firewall on this subnet, I thought gateway_enable="YES" in /etc/rc.conf should be sufficient. But it doesn't work. Do I need something else?

# cat /etc/rc.conf
ifconfig_re0="inet  netmask"

# sysctl net.inet.ip.forwarding
net.inet.ip.forwarding: 1

# netstat -rn
Routing tables

Destination        Gateway            Flags    Refs      Use  Netif Expire
default         UGS         0        0    rl0          link#6             UH          0        0    lo0    link#2             U           1      274    rl0     link#2             UHS         0        0    lo0    link#1             U           0       15    re0       link#1             UHS         0        0    lo0

Destination                       Gateway                       Flags      Netif Expire
::1                               ::1                           UH          lo0
fe80::%lo0/64                     link#6                        U           lo0
fe80::1%lo0                       link#6                        UHS         lo0
ff01:6::/32                       fe80::1%lo0                   U           lo0
ff02::%lo0/32                     fe80::1%lo0                   U           lo0

More information about the freebsd-questions mailing list