RE: Port FWD via 2 NAT

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

 



> Err... did you label your picture right according to what you said??
> POSTROUTING should be done on linux1 according to your graphs.
> PREROUTING should be done on linux2
>
> Also, we need to see all your rules as you may have a -j DROP somewhere
that might be blocking it ie. ( -P FORWARD -j DROP )

My all rules on Linux1:
iptables -t nat -A POSTROUTING -s 10.0.2.2/32 -o eth0 -j SNAT --to (public
address)
iptables -A PREROUTING -t nat -p tcp -d (public address) --dport 23 -j DNAT
--to 10.0.2.2:23

On linux2:
iptables -t nat -A POSTROUTING -s 10.0.5.0/24 -o eth0 -j SNAT --to 10.0.2.2
iptables -A PREROUTING -t nat -p tcp -d 10.0.2.2 --dport 23 -j DNAT --to
10.0.5.13:23

Port 23 is only an example. Please, help :(

Adi



[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