iperf2

Perform network throughput tests

Syntax:

iperf2 -s [ options ]

iperf2 -c server [ options ]

iperf2 -u -s [ options ]

iperf2 -u -c server [ options ]

Runs on:

QNX Neutrino

Options:

The general options include:

-B host
--bind host
Bind to host, an interface or multicast address.
-C
--compatibility
For use with older versions; don't send extra msgs.
-f k|m|K|M
--format k|m|K|M
The format to report: Kbits, Mbits, KBytes, MBytes.
-h
--help
Print a help synopsis.
-i n
--interval n
Pause for n seconds between periodic bandwidth reports.
-l n[K|M]
--len n[K|M]
Set the length of the read/write buffer to n (default 8 KB).
-M n
--mss n
Set the TCP maximum segment size (MTU - 40 bytes).
-m
--print_mss
Print the TCP maximum segment size (MTU - TCP/IP header).
-N
--nodelay
Set TCP no delay, disabling Nagle's Algorithm.
-o filename
--output filename
Output the report or error message to the specified file.
-p n
--port n
Set the server port to listen on/connect to to n (default 5001).
-u
--udp
Use UDP rather than TCP.
-v
--version
Print version information, and then exit.
-V
--IPv6Version
Set the domain to IPv6.
-w n[K|M]
--window n[K|M]
Set the TCP window size (socket buffer size).
-x C|D|M|S|V
--reportexclude C|D|M|S|V
Exclude C(connection), D(data), M(multicast), S(settings), or V(server) reports.
-y C|c
--reportstyle C|c
If set to C or c, report results as CSV (comma-separated values).

The server-specific options include:

-D
--daemon
Run the server as a daemon.
-s
--server
Run in server mode.
-U
--single_udp
Run in single-threaded UDP mode.

The client-specific options include:

-b n[K|M]
--bandwidth n[K|M]
Set the target bandwidth to n bits/sec (default 1 Mbit/sec). This setting requires UDP (-u).
-c host
--client host
Run in client mode, connecting to host.
-d
--dualtest
Do a bidirectional test simultaneously.
-F name
--fileinput name
Input the data to be transmitted from a file.
-I
--stdin
Input the data to be transmitted from stdin.
-L n
--listenport n
The port to receive bidirectional tests back on.
-n n[K|M]
--num n[K|M]
The number of bytes to transmit (instead of -t).
-P n
--parallel n
The number of parallel client threads to run.
-r
--tradeoff
Do a bidirectional test individually.
-T n
--ttl n
The time-to-live, for multicast (default 1).
-t n
--time n
The time in seconds to transmit for (default 10 secs).

Description:

The iperf2 tool measures network throughput. It can test either TCP or UDP throughput. To perform an iperf2 test, you must establish both a server (to discard traffic) and a client (to generate traffic).

For a different version of this tool, see iperf3.

Environment variables:

TCP_WINDOW_SIZE
Controls the size of TCP buffers.

Contributing author:

iperf2 was originally written by Mark Gates and Alex Warshavsky. Man page and maintence by Jon Dugan jdugan at x1024 dot net. Other contributions from Ajay Tirumala, Jim Ferguson, Feng Qin, Kevin Gibbs, John Estabrook jestabro at ncsa.uiuc.edu, Andrew Gallatin gallatin at gmail.com>, and Stephen Hemminger shemminger at linux-foundation.org.

See also http://iperf2.sourceforge.net/.