Re: Send local traffic to a different server.

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

 



On Wed, 2004-06-23 at 10:24, Antony Stone wrote:

> How are packets from the machine we are talking about routed to and from the 
> Internet?   Where is NAT taking place?

I got it working! Actually I was testing on Redhat Enterprise Linux ES 3
(RHEL) with no success so I went to Gentoo and was able to get it to
work with the following...

iptables -t nat -A OUTPUT -p tcp --dport 6000 -d 127.0.0.1 -j DNAT --to
207.156.7.115:80
iptables -t nat -A POSTROUTING -p tcp -d 207.156.7.115 -o eth0 --dport
80 -j SNAT --to-source 172.27.228.220

I suspect that RHEL doesn't have 'NAT of local connections' compiled
into the kernel.

Thanks for everyone help, 
Brett



[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux