iperf3 is an open-source tool for testing network performance (bandwidth). It allows to measure the maximum data transfer rate between two points and additional network parameters (e.g. delay, delay variations, packet loss). It works in a client-server architecture - a server (listening) is run on one host and a client initiating a connection on the other. iperf3 supports both TCP and UDP (or even SCTP), as well as IPv4 and IPv6. It is available on various systems (Linux, Windows, VMware, etc.) and is usually installed from the package manager (e.g. apt, yum).
-s) on one machine and in client mode (-c ) on the other. The client establishes a TCP connection to the server (default port 5201) and sends a data stream, which the server accepts and measures. The test is unidirectional - by default it is the client that sends data to the server. In UDP mode (with the option -u), the client sends UDP packets at a preset throughput (measurement can take into account packet loss and delay variation). Switch -R or --reverse reverses the direction of transmission: the connection is initiated by the client anyway, but it is the server that sends the data to the client.-b . By default with UDP iperf3 sets 1 Mbit/s, and with TCP no limit (the test takes 10 s by default).-t), the number of parallel streams (-P), or the output format (--json). The server and client should use the same port values (-p). Additionally, the flags -4/-6to force IPv4 or IPv6.-s, --server - runs iperf3 in server listening server mode. The server listens on the default port 5201 (can be changed from -p). In server mode, the programme accepts one connection from the client.-c , --client - starts the client modeby connecting to the specified server. Parameter specifies the IP address or name of the iperf3 server to which the client sends data.-t , --time - test duration in seconds. Default test duration is 10 s; option -t option allows you to change the duration.-p , --port - TCP/UDP port on which the server listens and to which the client connects. The default is 5201. Used when you need a non-standard port (e.g. due to network restrictions).-u, --udp - enables test in UDP mode instead of TCP mode. In UDP mode, the packet throughput can additionally be specified via the option -b.-b , --bandwidth - Target bandwidth for transmission. Format is, for example. 100M for 100 megabits/s. With UDP, this value indicates the packet sending rate (default: 1Mbit/s), and with TCP it can limit the stream (default: „unlimited”).-J, --json - test result displayed in JSON format (useful for further analysis).--logfile - saves the test result to the specified file, instead of (or in addition to) displaying it on screen.-R, --reverse - mode reversed: the client initiates the connection to the server, but it is the server that sends the data to the client. Allows the download speed to be measured, keeping the same connection path.-V, --verbose - Detailed diagnostic information about the test (optional).