iperf is a tool for performing network throughput measurements. It can test either TCP or UDP throughput. To perform an iperf test the user must establish both a server (to discard traffic) and a client (to generate traffic).
iperf -s [ options ]
iperf -c server [ options ]
iperf -u -s [ options ]
iperf -u -c server [ options ]
Let us say for example, we are going to test network performance between System A and System B.
System A is running with Debian 7 with IP Address 192.168.1.200/24 and System B is running with Ubuntu 13.04 with IP Address 192.168.1.59/24.
Install ‘iperf’ package on both System A and B with following command.
$ sudo apt-get install iperf
Test Network Performance
Run the following command in System A(Debian 7):
# iperf -s -B 192.168.1.200
-s – Run in Server mode.
-B – Bind To IP
Now go to System B(Ubuntu 13.04) and run the following command:
$ sudo iperf -c 192.168.1.200 -d -t 60 -i 10
-c – Run in client mode.
-d – Do Bidirectional Test On simultaneously.
-t 60 – Transmit second, default value is 10.
-i 10 – Pause 10 seconds between periodic bandwidth report.
On System A(Debian 7):
# man iperf