I'm running OpenWRT on an x86 box, and I want to use nping
to build more detailed probes for measuring latency. I've installed the nping package and it runs ok, but the results seem to be completely wrong, with latencies much higher than expected.
For example, here are some results from the standard ping
command:
root@XXXXXXXX:~# ping -c 5 9.9.9.9
PING 9.9.9.9 (9.9.9.9) 56(84) bytes of data.
64 bytes from 9.9.9.9: icmp_req=1 ttl=57 time=16.3 ms
64 bytes from 9.9.9.9: icmp_req=2 ttl=57 time=14.9 ms
64 bytes from 9.9.9.9: icmp_req=3 ttl=57 time=16.5 ms
64 bytes from 9.9.9.9: icmp_req=4 ttl=57 time=14.8 ms
64 bytes from 9.9.9.9: icmp_req=5 ttl=57 time=19.4 ms
--- 9.9.9.9 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4005ms
rtt min/avg/max/mdev = 15.470/18.369/26.812/4.248 ms
And here's the equivalent using nping (run immediately after the ping command above):
root@XXXXXXXX:~# nping --icmp -c 5 9.9.9.9
Starting Nping 0.7.70 ( https://nmap.org/nping ) at 2020-09-14 14:15 BST
SENT (0.0935s) ICMP [XX.XX.XX.XXX > 9.9.9.9 Echo request (type=8/code=0) id=9721 seq=1] IP [ttl=64 id=53052 iplen=28 ]
RCVD (0.2618s) ICMP [9.9.9.9 > XX.XX.XX.XXX Echo reply (type=0/code=0) id=9721 seq=1] IP [ttl=57 id=20217 iplen=28 ]
SENT (1.0938s) ICMP [XX.XX.XX.XXX > 9.9.9.9 Echo request (type=8/code=0) id=9721 seq=3] IP [ttl=64 id=53052 iplen=28 ]
RCVD (1.3118s) ICMP [9.9.9.9 > XX.XX.XX.XXX Echo reply (type=0/code=0) id=9721 seq=3] IP [ttl=57 id=20800 iplen=28 ]
SENT (2.0939s) ICMP [XX.XX.XX.XXX > 9.9.9.9 Echo request (type=8/code=0) id=9721 seq=4] IP [ttl=64 id=53052 iplen=28 ]
RCVD (2.1517s) ICMP [9.9.9.9 > XX.XX.XX.XXX Echo reply (type=0/code=0) id=9721 seq=4] IP [ttl=57 id=21231 iplen=28 ]
SENT (3.0959s) ICMP [XX.XX.XX.XXX > 9.9.9.9 Echo request (type=8/code=0) id=9721 seq=4] IP [ttl=64 id=53052 iplen=28 ]
RCVD (3.2018s) ICMP [9.9.9.9 > XX.XX.XX.XXX Echo reply (type=0/code=0) id=9721 seq=4] IP [ttl=57 id=21758 iplen=28 ]
SENT (4.0969s) ICMP [XX.XX.XX.XXX > 9.9.9.9 Echo request (type=8/code=0) id=9721 seq=5] IP [ttl=64 id=53052 iplen=28 ]
RCVD (4.2518s) ICMP [9.9.9.9 > XX.XX.XX.XXX Echo reply (type=0/code=0) id=9721 seq=5] IP [ttl=57 id=22517 iplen=28 ]
Max rtt: 217.887ms | Min rtt: 57.819ms | Avg rtt: 140.875ms
Raw packets sent: 5 (140B) | Rcvd: 5 (230B) | Lost: 0 (0.00%)
Nping done: 1 IP address pinged in 4.33 seconds
Note the very long (and I would assert incorrect) round-trip times, which make nping pretty much useless. Does anyone have any idea why this is happening and how I can fix it?