Here are some simple steps to do it, using Network Address Translation (NAT)

  1. Enable packet forwarding . Make it permanent by adding “net.ipv4.ip_forward = 1” to /etc/sysctl.conf

    echo “1” > /proc/sys/net/ipv4/ip_forward

  2. Enable iptables to handle NAT. ( eth0 is the public connection )

    /sbin/iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE

  3. Save iptables settings

    service iptables save

  4. Done. Check by routing table by verifying “netstat -nr” and iptables rules by “iptables -L”

This is a simple method for Redhat Enterprise Linux. See iptables docs for more detailed info.

Leave a Reply

Your email address will not be published. Required fields are marked *

You May Also Like
Read More


Dmidecode reports information about your system’s hardware as described in your system BIOS. This command gives you vendor…
Read More

Netapp deduplication

Netapp deduplication – is a new technology to control the rate of data growth. The average UNIX or…
Read More

Perl : Xen API

Xen host can be monitored and controlled via Xen API ( it uses XML-RPC communications). Here is a…