4 ms·
I had to do something like this at home with a flaky cable connection. It was a 100Mbs connection, or maybe 200Mbs. Several years ago, but fastest I could get.
by hnbear 4y ago
I had to do something like this at home with a flaky cable connection. It was a 100Mbs connection, or maybe 200Mbs. Several years ago, but fastest I could get. Periodically it would drop to 5Mbs or so, nothing faster. The ISP came and said they'd changed the cable, changed the connection on the pole, etc, and started pushing for evidence.
So, I wrote a script that periodically did a speed test, but I had it test 3 different sites, and average the result. Because when it was slow it was so slow I wrote a back-off function (or maybe ramp up, I can't remember), so I can determine the actual speed, given available bandwidth. Did something like test a 1Mb download, then if that was quick 10Mb, then 100Mb, to get a sustained throughput speed, and average across download sources.
If it was shown to be slow it bounced the modem. I was using the ISP cable modem because after all the complaining I did want them to have any complaints about me using a custom one, so had to reverse engineer the correct call to the shitty web-site it presented.
Anyway, it ended up working really well, and kept their engineers off my back whenever they came round to ask if I'd bounced the modem, or whatever basic troubleshooting. I could show them the script, show them the metrics it kept (daily and hourly averages), and they'd instantly get more serious with their answers.
I never got to the flashing light stage though, maybe should have done that too.