Weird ICMP latency between 2 networks

Hello,

I have two networks:

  • Primary network (no VLAN), on ether2: 10.0.1.0/24


  • VLAN2 (also on ether2): 10.0.2.0/24

(VLAN2 is used for my testing and lab environment.)

The problem is, when I try to ping my Ubuntu machine in VLAN2 from either my PC or the MikroTik router (primary network), the latency is very high:

sent=20 received=20 packet-loss=0% min-rtt=2.248ms avg-rtt=131.803ms max-rtt=297.132ms

However, when I ping the MikroTik router from the Ubuntu machine in VLAN2, the latency is fine — around 1ms. So that direction is working properly.

Here’s what’s really strange:

If I connect to the Ubuntu machine (10.0.2.50) using RDP from my Windows PC (10.0.1.10), and then try to ping the Ubuntu machine from the PC or the MikroTik, the latency drops to 1–2ms. But as soon as I minimize the RDP session, the ping latency goes back up to 200ms+.

What the hell is going on? Can someone explain/help me ?

tl;dr

  • ICMP latency from my primary network 10.0.1.0/24 to my Ubuntu test server 10.0.2.50 is 200+ms, either from PC 10.0.1.10 also form Mikrotik 10.0.1.1


  • ICMP from Ubuntu test server 10.0.2.50 to Mikrotik 10.0.2.1 is 1-2ms, it’s OK

Thank you.

Right after I sent that response, I thought about it again — the latency decreases when I RDP into the machine. This Ubuntu machine is connected via a Wi-Fi adapter, and Wi-Fi adapters have a power management setting. I checked using iwconfig and saw that Power Management was enabled (Power Management:on). I turned it off using:

iwconfig wlp2s0 power off

Sometimes it’s good to write up problem, your brain will figure it out eventually.

And the crucial detail (WLAN being in the mix) was missing from your initial description. If you didn’t get to the right conclusion yourself, somebody else might have spotted the reason … but only in case when all the details are present in the description.

Yes, that’s right - It is crucial detail, which i forgot to mention.