0

For the past month, I've been experiencing intermittent high ping to my home router from all the computers on my WiFi network. For every ten pings or so, the ping will climb from the acceptable value of 1-3 ms to about 800 ms.

There are already similar questions on ServerFault and Superuser with some very good answers. A particular answer on Superuser noted that applying a load on the network (for example, running μTorrent), seemed to eliminate the high ping.

I tried it and found the same results. Here are ping values from PingPlotter: ping log

Note that the graph becomes flat as soon as I turn on μTorrent.

Instead of having μTorrent on all the time, I'm currently looking to create a lightweight program that can apply a load on the network. I tried compiling the Rust program provided on the Superuser answer, but I ended up getting the following error:

error: macro undefined: 'log!'
  --> rust.rs:11:7
   |
11 |       log! ("wifi_load] Error fetching {}: {}", url, err);
   |       ^^^

error: aborting due to previous error

So how can I create a program that would acheive an effect similar to turning on μTorrent? I'd like to note that I'm not a programmer and I don't necessarily need to use Rust — just need to accomplish the objective.

Thanks!

4
  • What operating system? And have you tried the more traditional fixes for this problem such as adjusting power management and changing roaming aggressiveness? Nov 18, 2016 at 9:18
  • μTorrent was on a Windows laptop, but pretty much all computers on the network experienced high ping to the router: a desktop, a MacBook and an Android phone. As for adjusting power management and changing roaming aggressiveness Hmm, no. I've never found these solutions in the research I've done so far. Can you provide some links? The one other thing I'm trying is to check the electrical grounding in my house. I've ordered a socket tester for this, and it's yet to arrive.
    – Vikram
    Nov 18, 2016 at 9:28
  • Just punch "windows wifi ping" into your favorite search engine. The first several hits will cover it. Also, see this and this. Nov 18, 2016 at 9:34
  • After turning off auto configuration logic using the netsh command, it seems to have solved the problem! :D
    – Vikram
    Nov 19, 2016 at 8:24

1 Answer 1

0

Once-per-second pings over mostly-idle Wi-Fi are a terrible way to look for latency problems, because you're not actually measuring what you think you're measuring. The problem is that Wi-Fi clients are usually battery-powered, and like to save power by using 802.11 Power Save mode, which turns the Wi-Fi radio off for brief periods of time (perhaps a few tenths of a second, but it adds up) when there doesn't seem to be any traffic to send or receive.

Once-per-second pings are not enough traffic to keep 802.11 Power Save mode from kicking in, so you can see longish ping times because of Power Save mode.

To test this theory, try running 20 pings per second. Not sure about Windows, but on Linux or macOS it would be this: sudo ping -i 0.05 192.168.0.1. This makes you send (and receive) two pings per 802.11 beacon interval (which is usually a tenth of a second), which is usually enough to keep Power Save from kicking in.

Running unnecessary traffic to keep Power Save mode from kicking in is pretty silly. It's like saying, "Hey, my car engine revs down to idle speeds when I'm stopped at a stoplight! Should I keep my foot on the gas to keep the engine revved up while I'm at the stoplight?" The answer is "No, letting it rev down is saving energy. It'll rev right back up again when you need it!"

1
  • In theory, your answer makes perfect sense. However, in practice, I consistently found that the internet got slow exactly when the ping jumped. However, I've now solved it using the netsh command as I noted in my comment above. Also, I'm not sure how to perform 20 pings per second on Windows.
    – Vikram
    Nov 19, 2016 at 8:25

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .