Measuring Latency on Debian Linux Clusters HOWTO  
Network latency is the time it takes for a small packet to travel from a sender to a receiver and back (the round-trip time). Latency is partly due to the time the signal travels within the copper wires or the fiberoptics (close to the speed of light), although such is generally small (about 0.005 $\mu$s per meter of cable). A more significant source of latency is the encoding of the packets (around 20 $\mu$s for RJ45 encoding and less for SFP+ encoding). A third source of latency is not related to the network itself but to the bus and IP stack — such can amount to as much as 20$\mu$s of waiting time.
Low network latency — more so than high network bandwith — leads to better parallelization efficiency of CFDWARP.
Network latency between two hosts on your cluster can be measured through netperf (accurately) or ping (approximately).
Clone the latest netperf source from Hewlett-Packard on github:
git clone
Within the netperf directory, do the following to generate the Makefiles:
Then, compile netperf:
This will create the netperf and netserver executables within netperf/src. On the receiving machine (, start the network server:
On the sending machine (, run the program netperf as follows:
./netperf -H -l 10 -t TCP_RR -w 10ms -b 1 -v 2 -- -O min_latency,mean_latency,max_latency,stddev_latency,transaction_rate
where TCP_RR can be substituted for UDP_RR.
Note that netperf gives an accurate reading of the latency even when the network is under load.
Another way to find the latency is using the ping utility using root access. Type the following to send packets every 10 ms:
sudo ping -c 1000 -i 0.010
Note that ping will not give an accurate reading of the latency especially when the network is under load.
PDF 1✕1 2✕1 2✕2