Linux router configuration:
a, set the IP address of two network cards
B, # iptables -t nat -a postrol -j masquerade
C, # echo 1> / proc / sys / net / ipv4 / ip_forward
D, the machine default gateway inside the subnet sets into the IP address of the Linux router
e, in order to knock the above two statements after each restart computer,
You can add this two sentences in /tc/rc.d/rc.local.