I've installed Mikrotik hEX at location 'A', Mikrotik hAP AC^2 at location 'B', and connected each with OVPN L2. Both two routers have their NAT features turned on, and have their private network. hEX has network 192.168.0.0/23, and hAP has network 192.168.3.0/24. These two local networks are are bound as one local network 192.168.0.0/22. I've confirmed all bridge, routing and DHCP policy are configured and worked as I expected.
After configuring above setting, I'm trying to connect to an public IP ('X') from device attached under hEX, to use this route.
End device -> hEX -> hAP -(NAT)-> Remote server 'X'
To accomplish this, I've added routing policy to 'X' to use IP of VPN server binding interface on hEX as gateway, and confirmed ICMP echo reply is well received, stable, and requires about 9-12 ms to be replied.
However, when I use any software which is using TCP to establish connection(I've not confirmed if UDP is being affected too, but I think it is negative.), something strange happens like this:
Even other TCP packets are replying ASAP, under 50 msec, if TCP connection is established. However, only TCP ACK packet replying SYN, ACK of server is keep being retransmitted for about 10 secs and then handshake process is continued. This behavior is also found while HTTPS connection is established, and is observed at all devices under hEX.
If I remove routing policy to address X, then use route
End device -> hEX -(NAT)-> Remote server 'X', TCP handshake is immediately established.
If I connect to address X on device under hAP, by using route
End device -> hAP -(NAT)-> Remote server 'X', TCP handshake is immediately established.
What is the problem, and how should I fix it?