How to make a linux server act as a gateway

1. turned on IP forwarding in sysctl.conf by setting the value to 1
2. gave the ip tables command for nat masquerade.
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE
Checked that the commands took effect by:
iptables-save
and then made the entries from iptables-save inside the file /etc/sysconfig/iptables

Comments

Popular posts from this blog

How do I Use the Linux Top Command?

IOPS measurement