To manage NAT properly first thing we need to do is to allow IP FORWARDING
so we will edit following file
nano /etc/sysctl.conf
find the following line
net.ipv4.ip_forward
and change that to
net.ipv4.ip_forward = 1
once done, please issue following iptables commands
# /sbin/iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE # /sbin/iptables -A FORWARD -i eth0 -o eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT # /sbin/iptables -A FORWARD -i eth1 -o eth0 -j ACCEPT # /sbin/iptables save
Thank you ever so for you article. Thanks Again. Want more. Adelaide Pace Jedthus