I want to make NAT from local to public IP 1:1 . But I have two internet gateways and it can happends, packet can go thru IGW1 to internet and packet can return thru IGW2.
I made same IP FIREWALL NAT rules on both IGWs:
Code: Select all
ip firewall nat add chain=srcnat action=netmap to-addresses=220.127.116.11 src-address=10.140.4.2 ip firewall nat add chain=dstnat action=netmap to-addresses=10.140.4.2 dst-address=18.104.22.168
When packet is returning from the internet by the same IGW , where srcnat was done (packet goes to internet by the same IGW), everything works OK:
But when packet is returning from the internet by the second IGW, where srcnat was not done (packet goes to internet by IGW1 but answer come to IGW2), NAT is not working:in:wan out:lan, proto ICMP (type 0, code 0), 22.214.171.124->10.140.4.2, NAT 126.96.36.199->(188.8.131.52->10.140.4.2), len 56
I suppose, there is problem, because there is not established connection in connection tracking table. But I want to make NAT 1:1 and ignore connection tracking table ... not matter, if connection is established or not.in:wan out:wan, proto ICMP (type 0, code 0), 184.108.40.206->220.127.116.11, len 56