Map the IP ports of the two WAN ports to the same intranet Port. the IP addresses of the two WAN ports on the server are 192.168.30.155 and 192.168.80.155. The intranet IP address is 192.168.1.1. the client IP address is 192.168.1.138 (eth1) port 8080 to port 21 iptables-tnat-APREROUTING-d192.168.30.155 maps the IP ports of two WAN ports to the same intranet Port
The IP addresses of two WAN ports on the server are 192.168.30.155 and 192.168.80.155, and the intranet IP address is 192.168.1.1.
The client IP address is 192.168.1.138 (eth1)
In the linux command line, enter the following command to configure the route from which interface to which: (configure the policy route)
Ip route add default via 192.168.30.1 dev eth0 src 192.168.30.155table 1
Ip rule add from 192.168.30.155 table 1
Ip route add default via 192.168.80.1 dev eth2 src 192.168.80.155table 2
Ip rule add from 192.168.80.155 table 2
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service