Slow NAT performance ?

Slow NAT performance ?

Post by Mike Gleas » Thu, 19 May 2005 06:37:31


Hi all,

I have this setup :

Cable Modem
|
|
FreeBSD (2 NICs)
192.168.2.1 and the other DHCP
|
|
Exteral wireless router (NAT Disabled)
192.168.2.2
|
|
Wireless Clients (No DHCP, WEP disabled)
192.168.2.3 to 192.168.2.254


From a client (192.168.2.3) I am able to ping
everyone (192.168.2.1, 192.168.2.2)

From the same client (192.168.3.1),
If I tranfer a file with FTP to 192.168.2.1
I get ~600 kbps (upload or download).

But if I download a file from the Internet
from the same client, I get only 200 kbps.
While if I issue the command fetch on the
FreeBSD server on the same file I get
~500 kbps

So the bandwith from clients to the freebsd
server is not a problem, I get 600 kbps ftp...
The Internet connection is not a problem,
a fetch cmd from the server gets 500kbps...
But when a client is accessing the Internet,
it is slow... 200 kbps...

Here is my ipnat.rules :
map rl0 0/0 -> 0/32 proxy port ftp ftp/tcp
map rl0 192.168.2.0/24 -> 0/32 proxy port ftp ftp/tcp
map rl0 192.168.2.0/24 -> 0/32 portmap tcp/udp 20000:30000
map rl0 192.168.2.0/24 -> 0/32

My ipf.rules is : (dc0 is 192.168.2.1)
pass in quick on dc0 all
pass out quick all on dc0 all

My Server:
FreeBSD xxxx.xxx.org 5.3-RELEASE FreeBSD 5.3-RELEASE #2: Mon May 16 17:48:19
EDT 2005 XXXX@XXXXX.COM :/usr/src/sys/i386/compile/GATEWAY i386

Thank you,
Mike