Masquerading on OpenStack Router not working

asked 2016-09-07 12:27:27 -0500

Saminder13 gravatar image

Hello

I am working on a scenario where i want to implement IP masquerading on OS router specific port for the outgoing packets from a particular tenant network.

I tried sudo ip netns exec qrouter-1faa6c68-7719-4a2c-b92c-4961cac27ada iptables -t nat -A POSTROUTING -s 20.0.0.0/16 -o qr-b053ed0b-43 -j MASQUERADE where qrouter-1faa6c68-7719-4a2c-b92c-4961cac27ada is namespace value of the the OS router and qr-b053ed0b-43 is outgoing port where i want to do masquerading given by ifconfig -a output.

When i try sudo ip netns exec qrouter-1faa6c68-7719-4a2c-b92c-4961cac27ada iptables -t nat -L -v masquerading is shown for POSTROUTING. However, in reality it seems to be not working because the the packets i received at other end still have original source ip addresses.

Thanks in advance.

edit retag flag offensive close merge delete