iPerf3 is the industry-standard **CLI tool** for active measurements of the maximum achievable **network bandwidth** between different hosts. It is an essential utility for SysAdmins to accurately diagnose and rule out network throughput issues.
We will begin by installing the server component on a vanilla pfSense Community Edition firewall. pfSense uses its own package managing system for installation:
iPerf3 är det industristandardiserade CLI-verktyget för aktiva mätningar...
iperf.Once installed, you must start the service, which is found under Diagnostics:
The server will run in the background. You can navigate away from this window without interrupting the test.
We will now set up the client on a separate Ubuntu Linux machine to run our first test against the pfSense server.
Open a terminal and install iPerf3 using the package manager:
# Become root and update system
sudo su -
apt update && apt upgrade -y
# Install iPerf3
apt install iperf3 -y
To connect to the iPerf3 server running on pfSense, use the -c (client) flag followed by the server's IP address:
# Replace [SERVER_IP] with the pfSense IP
iperf3 -c [SERVER_IP]
This command performs a default TCP bandwidth test using **one stream** for **10 seconds**.
In a realistic scenario (like video streaming or heavy downloads), multiple parallel TCP streams are used. To avoid throttling caused by single-stream limitations (often CPU-related, such as on pfSense), use the -P flag to specify the number of streams (e.g., 10):
iperf3 -c [SERVER_IP] -P 10
Using parallel streams often results in a significantly higher and more realistic bandwidth result (e.g., jumping from 650 Mbits to 1.5 Gbits).
You can specify how long the test should run using the -t flag (in seconds):
# Runs a test for 15 seconds using 10 parallel streams
iperf3 -c [SERVER_IP] -P 10 -t 15
The procedure on Windows Server (or any modern Windows system) involves downloading the executable since there is no built-in package manager like apt.
iperf-*-win64.zip)..\iperf3.exe -c [FIREWALL_IP]
You can also run the Windows machine in server mode using the -s flag:
.\iperf3.exe -s
iPerf3 Port 5201).To measure your true WAN throughput (speed through your home router and ISP), you can test against public iPerf3 mirrors found online. These mirrors often listen on non-default ports.
To specify a different port (e.g., 9200) use the -p flag:
# Example connecting to a public server on a custom port with 8 streams
iperf3 -c speedtest.fr -p 9200 -P 8
Always use **parallel streams** when testing against WAN links to get the most accurate result of your available bandwidth.