How To
Summary
iPerf is a widely used command-line tool designed for measuring network performance by generating TCP and UDP traffic between two endpoints. It allows network administrators, engineers, and individuals involved in network troubleshooting and performance tuning to assess network throughput, latency, packet loss, and other metrics.
Objective
- Download iPerf
- Install iPerf
- Run iperf as server and client
- Where to look to determine throughput
Environment
Steps
---------------------------------------------------------------------------------
Installing iperf:
https://www.ibm.com/support/pages/aix-toolbox-open-source-software-downloads-alpha
- Copy iperf3-nnn.nnn.ppc.rpm in /tmp dir
- Run "rpm -Uvh /tmp/iperf3-nnn.nnn.ppc.rpm"
- The rpm command creates /usr/bin/iperf
iperf -s -w 512k
iperf -c <ipaddress of host A> -P 24 -t 180 -l 64k -w 512k
iperf
provides a wide range of options and settings that allow you to customize the test parameters, such as the test duration, port number, TCP/UDP mode, and more. You can refer to the iPerf
documentation or use the iperf --help
command to explore the available options.A man-page for iperf can be found readily online. Here is the usage output from the iperf command:
Usage: iperf [-s|-c host] [options]
iperf [-h|--help] [-v|--version]
Client/server:
-f, --format [kmKM] format to report: Kbits, Mbits, KBytes, MBytes
-i, --interval # seconds between periodic bandwidth reports
-l, --len #[KM] length of buffer to read or write (default 8 KB)
-m, --print_mss print TCP maximum segment size (MTU - TCP/IP header)
-o, --output <filename> output the report or error message to this specified file
-p, --port # server port to listen on/connect to
-u, --udp use UDP rather than TCP
-w, --window #[KM] TCP window size (socket buffer size)
-B, --bind <host> bind to <host>, an interface or multicast address
-C, --compatibility for use with older versions does not sent extra msgs
-M, --mss # set TCP maximum segment size (MTU - 40 bytes)
-N, --nodelay set TCP no delay, disabling Nagle's Algorithm
-V, --IPv6Version Set the domain to IPv6
Server specific:
-s, --server run in server mode
-U, --single_udp run in single threaded UDP mode
-D, --daemon run the server as a daemon
Client specific:
-b, --bandwidth #[KM] for UDP, bandwidth to send at in bits/sec
(default 1 Mbit/sec, implies -u)
-c, --client <host> run in client mode, connecting to <host>
-d, --dualtest Do a bidirectional test simultaneously
-n, --num #[KM] number of bytes to transmit (instead of -t)
-r, --tradeoff Do a bidirectional test individually
-t, --time # time in seconds to transmit for (default 10 secs)
-F, --fileinput <name> input the data to be transmitted from a file
-I, --stdin input the data to be transmitted from stdin
-L, --listenport # port to receive bidirectional tests back on
-P, --parallel # number of parallel client threads to run
-T, --ttl # time-to-live, for multicast (default 1)
-Z, --linux-congestion <algo> set TCP congestion control algorithm (Linux only)
Miscellaneous:
-x, --reportexclude [CDMSV] exclude C(connection) D(data) M(multicast) S(settings) V(server) reports
-y, --reportstyle C report as a Comma-Separated Values
-h, --help print this message and quit
-v, --version print version information and quit
[KM] Indicates options that support a K or M suffix for kilo- or mega-
The TCP window size option can be set by the environment variable
TCP_WINDOW_SIZE. Most other options can be set by an environment variable
IPERF_<long option name>, such as IPERF_BANDWIDTH.
------------------------------------------------------------
Client connecting to 192.168.1.100, TCP port 5001
TCP window size: 85.0 KByte (default)
------------------------------------------------------------
[ 3] local 192.168.1.101 port 54536 connected with 192.168.1.100 port 5001
[ ID] Interval Transfer Bandwidth
[ 3] 0.0-10.0 sec 1.07 GBytes 917 Mbits/sec
Analysis:
- The client is connecting to the server with IP address 192.168.1.100 and using TCP port 5001.
- The TCP window size is set to the default value of 85.0 KByte.
- The connection is established between the client (192.168.1.101) and the server (192.168.1.100) on port 5001.
- The test ran for a duration of 10 seconds (0.0-10.0 sec).
- During the test, 1.07 gigabytes of data were transferred.
- The measured bandwidth is 917 megabits per second (Mbps).
Based on this example, the analysis can be as follows:
- The bandwidth of 917 Mbps indicates the network's capacity to transmit data. Higher values generally indicate better performance.
- The TCP window size of 85.0 KByte might impact the maximum achievable bandwidth. Increasing the TCP window size could potentially improve performance in certain scenarios.
- The test ran for 10 seconds, providing a decent time window for measuring network performance.
- No packet loss or latency values are presented in this particular output, but those metrics are crucial for assessing network quality.
To conduct a more comprehensive analysis, additional information such as latency, jitter, and packet loss is necessary. These values, along with benchmark comparisons and consideration of the network environment, provide a more complete understanding of the network's performance characteristics.
AIX Toolbox for Open Source Software Tips |
---|
Download :
The AIX Toolbox team recommends using DNF to install and manage Open Source software packages and dependencies Visit Get Started to learn more about DNF and the dnf_aixtoolbox.sh installation script. Read What's New in the AIX Toolbox for Open Source Software
Get Help for AIX Toolbox for Open Source Software
|
Additional Information
SUPPORT |
---|
If you require more assistance, use the following step-by-step instructions to contact IBM to open a case for software with an active and valid support contract. 1. Document (or collect screen captures of) all symptoms, errors, and messages related to your issue. 2. Capture any logs or data relevant to the situation. 3. Contact IBM to open a case: -For electronic support, see the IBM Support Community: 4. Provide a clear, concise description of the issue. - For more information, see: Working with IBM AIX Support: Describing the problem. 5. If the system is accessible, collect a system snap, and upload all of the details and data for your case. - For more information, see: Working with IBM AIX Support: Collecting snap data |
Related Information
Was this topic helpful?
Document Information
Modified date:
14 December 2023
UID
ibm10886387