linux - SNAT does not change source ip -
i trying nat internal virtual network (adapter tun0 ip: 10.8.0.x - vpn network) outer world (adapter venet0:0 ip xxx.xxx.xxx.xxx)
i using following iptables rule:
iptables -t nat -a postrouting -s 10.8.0.0/24 -o venet0:0 -j snat --to xxx.xxx.xxx.xxx for reason iptables not changing outbound ip address:
tcpdump 08:23:17.863971 ip 10.8.0.6 > 8.8.8.8: icmp echo request, id 3887, seq 1264, length 64 netstat-nat proto nated address destination address state udp 10.8.0.6:61339 google-public-dns-a.goo:domain unreplied any ideas? doing wrong?
(ip_forward activated!)
you need configure nat on hardware node. check out article https://openvz.org/using_nat_for_container_with_private_ips
Comments
Post a Comment