Open Linux host kernel package forwarding function
# echo 1> / proc / sys / net / ipv4 / ip_forward
Configure network interface
# ifconfig ethx xxx.xxx.xxx.xxx UP
Add route
# Route add -net xxx.xxx.xxx.0 / xx ethx
Note: To turn on the kernel package forwarding function every time you start, you need to write the startup script.
# echo "echo 1> /Proc/sys/net/ipv4/ip_forward">> - Rc.d/rc.local