[linux/net]策略路由实现特定主机特定路径
ip rule add from 10.192.0.230 table silence ip rule add from 10.192.0.231 table silence ip rule add from 10.192.0.232 table silence ip rule add from 10.192.0.233 table silence ip rule add from 10.192.0.234 table silence ip rule add from 10.192.0.235 table silence ip rule add from 10.192.0.236 table silence ip route add default via 117.172.xxx.1 dev eth2 table silence iptables -t nat -A POSTROUTING -s 10.192.0.230/32 -j SNAT --to-source 117.172.xxx.17 iptables -t nat -A POSTROUTING -s 10.192.0.231/32 -j SNAT --to-source 117.172.xxx.17 iptables -t nat -A POSTROUTING -s 10.192.0.232/32 -j SNAT --to-source 117.172.xxx.17 iptables -t nat -A POSTROUTING -s 10.192.0.233/32 -j SNAT --to-source 117.172.xxx.17 iptables -t nat -A POSTROUTING -s 10.192.0.234/32 -j SNAT --to-source 117.172.xxx.17 iptables -t nat -A POSTROUTING -s 10.192.0.235/32 -j SNAT --to-source 117.172.xxx.17 iptables -t nat -A POSTROUTING -s 10.192.0.236/32 -j SNAT --to-source 117.172.xxx.17
郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。