iperf

From RaySoft

iperf is a tool for active measurements of the maximum achievable bandwidth on IP networks. It supports tuning of various parameters related to timing, protocols, and buffers. For each test it reports the bandwidth, loss, and other parameters.[1]

Documentation

Further Information

Syntax

iperf3 --server [PARAMETER ...]
iperf3 --client SERVER [PARAMETER ...]

Parameters

General parameters
The following parameters descriptions apply to the server and the client:
-f [kmgtKMGT], --format [kmgtKMGT]
Format to report: Kbits/Mbits/Gbits/Tbits.
-i NUMBER, --interval NUMBER
Pause NUMBER seconds between periodic throughput reports; default is 1, use 0 to disable.
--logfile FILE
Send output to a log FILE.
-p NUMBER, --port NUMBER
Set server port to listen on/connect to to NUMBER (default 5201).
Server
The following parameters descriptions apply only to the server:
-s, --server
Run in server mode.
-D, --daemon
Run the server in background as a daemon.
Client
The following parameters descriptions apply only to the client:
-c, --client host
Run in client mode, connecting to the specified server. By default, a test consists of sending data from the client to the server, unless the -R flag is specified.
-4, --version4
Only use IPv4.
-6, --version6
Only use IPv6.
-b NUMBER[KM], --bitrate NUMBER[KM]
Set target bitrate to NUMBER bits/sec (default 1 Mbit/sec for UDP, unlimited for TCP/SCTP). Setting the target bitrate to 0 will disable bitrate limits (particularly useful for UDP tests).
-R, --reverse
Reverse the direction of a test, so that the server sends data to the client.
-u, --udp
Use UDP rather than TCP.

Examples

Start the server...
iperf3 --server --format 'M'
... test sending data over TCP to the server
iperf3 --client 'xeon.raysoft.loc' --version4 --format 'M'
... test sending data over UDP to the server
iperf3 --client 'xeon.raysoft.loc' --version4  --format 'M' \
  --udp --bitrate 0
... and test receiving data over TCP from the server
iperf3 --client 'xeon.raysoft.loc' --version4  --format 'M' --reverse
... and test receiving data over UDP from the server
iperf3 --client 'xeon.raysoft.loc' --version4  --format 'M' --reverse \
  --udp --bitrate 0

References