Ping results are sometimes wrong
Don Lewis
truckman at FreeBSD.org
Sat May 17 10:55:33 PDT 2003
On 17 May, Brett Glass wrote:
> Just noticed that FreeBSD's ping program was giving me inaccurate stats when
> pinging hosts on the local subnet (but not on remote subnets). Some
> investigation has revealed why: the delay for the very first ping includes the
> time (if any) it takes to use ARP to discover the MAC address of the target.
> This introduces an outlying data point that messes up the stats; it makes them
> look as if there are extra delays or congestion on the network.
>
> Perhaps the program should make sure that the MAC address of the target (if
> it's on the local network) has been resolved before starting to ping?
You could have the same problem when pinging through a router that
doesn't have the MAC address of the target, and ping doesn't have a way
to check that. It would be simpler to just ignore the first sample when
calculating the statistics.
More information about the freebsd-net
mailing list