Help with iptables
In a howto i found this:
iptables -t nat -A POSTROUTING -o ethX -j MASQUERADE
This is for nat(of course).
I have some questions about this:
I have 4 ethernet cards in 1 machine, 2 with real ip (each one with 100mbit conection) (eth2 and eth3) and 2 with private networks with class C 192.168.1.0 and 192.168.2.0 (eth0 and eth1)
I want :
1.- one machine in the 192.168.1.0 network (host 192.168.1.4) use eth2.
2.- 2 machines in 192.168.2.0 use eth2.
3.- al other machines left in networks 192.168.2.0 and 192.168.1.0 use eth3.
Making normal routes no work.
I made the conclusion that is only with iptables, how i can do that?
thankz.-
|