In this guide, you will learn how to install and use iPerf3, a powerful CLI tool for measuring network bandwidth between different hosts. This tool is essential for ruling out network bandwidth issues. We will cover installation on pfSense, Ubuntu Linux, and Windows Server, and demonstrate how to run performance tests between them.
We will begin by setting up the server side of the test on a pfSense firewall. pfSense utilizes a package manager which makes installation very straightforward.
Navigate to System and select Package Manager. Go to the "Available Packages" tab and search for "iperf". Locate iperf3 and click the green install button to confirm the installation.
Once installed, the service is not found under the standard Services menu. Instead, go to Diagnostics and select iPerf.
To run the server:
5201.The server will now run in the background, allowing you to navigate away from the page while testing continues.
Next, we will configure an Ubuntu machine to act as the client and test connectivity to the pfSense server.
Open your terminal. It is best practice to update your repositories before installation.
sudo su
apt update
apt upgrade
Once the system is updated, install iPerf3:
apt install iperf3
To connect to the pfSense server, use the following command syntax (replacing the IP address with your server's IP):
iperf3 -c 192.168.1.99
This initiates a default TCP bandwidth test with one stream for 10 seconds. You will see a summary of the transfer and bandwidth (e.g., 650 Mbits/sec) upon completion. If testing VM-to-VM, your CPU might throttle the speed.
To simulate a more realistic scenario, such as video streaming or heavy internet usage, you should use multiple parallel TCP streams. This is done using the -P flag followed by the number of streams.
iperf3 -c 192.168.1.99 -P 10
This often results in higher throughput (e.g., 1.5 Gbits/sec) as it utilizes more available bandwidth.
You can also specify the duration of the test using the -t flag. For example, to run a test for 15 seconds:
iperf3 -c 192.168.1.99 -t 15
The procedure for Windows Server (tested here on Server 2025) is similar to other modern Windows systems.
Search for "iPerf3" and locate the official GitHub release page (avoiding third-party sites when possible). Download the standard client version, typically named iperf-version-win64.zip.
Extract the contents of the zip file. You will see an executable file (iperf3.exe) and a DLL file.
Right-click inside the folder and choose "Open in Terminal" or open a Command Prompt and navigate to the folder.
To run it as a client connecting to the pfSense server:
iperf3 -c 192.168.1.99
To enable the Windows machine to receive traffic (act as a server), use the -s flag:
iperf3 -s
The server will listen on port 5201 by default.
When running iPerf3 as a server on Windows, the default firewall settings will likely block incoming connections. You must create an inbound rule.
Open Windows Defender Firewall with Advanced Security.
Once the rule is active, you can return to your Ubuntu client and test the connection to the Windows machine:
iperf3 -c 192.168.1.104
You can also test your internet bandwidth by connecting to public iPerf3 servers. A list is available on the official iPerf homepage.
Public servers often listen on specific ports. Use the -p flag (lowercase) to specify the port.
iperf3 -c speedtest.fr -p 9200
Single-stream connections over the internet often yield lower results due to latency and window scaling. Use parallel streams to saturate the line:
iperf3 -c speedtest.fr -p 9200 -P 10
This will typically provide a much more accurate representation of your available bandwidth capacity.