The quick and simple way is to edit /etc/sysctl.conf and make this change
Code:
net.ipv4.ip_forward = 1
Then run this
Code:
echo "1" > /proc/sys/net/ipv4/ip_forward
Then turn on masquerading add this to your /etc/sysconfig/iptables
Code:
*nat
:PREROUTING ACCEPT [0:0]
:POSTROUTING ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
-A POSTROUTING -o <external_interface> -j MASQUERADE
COMMIT
And restart iptables.