chenyx 发表于 2012-03-07 14:23
开启ip转发,然后添加一条nat规则:
iptables -A POSTROUTING -s 192.168.8.0/24 -j MASQUERADE
chenyx 发表于 2012-03-07 14:23
开启ip转发,然后添加一条nat规则:
iptables -A POSTROUTING -s 192.168.8.0/24 -j MASQUERADE
chenyx 发表于 2012-03-07 14:50
sorry,写错了,少写一个-t nat,应该是
iptables -t nat -A POSTROUTING -s 192.168.8.0/24 -j MASQUERADE
欢迎光临 Chinaunix (http://bbs.chinaunix.net/) | Powered by Discuz! X3.2 |