iPerf is a measurement tool to test throughput in IP networks. It is best to run an iPerf test in scenarios where there is low throughput, packet loss, or latency experienced by users.
For example, if users within an organization are complaining about experiencing slowness when downloading a file from the internet or slowness in browsing websites.
In the below setup, FortiGate-101F is selected as the device, and the iperf speed test is between the Windows client connected on port1 and the Windows server connected on wan1.

iPerf needs to be installed on client machine 192.168.10.2 and server machine 172.16.10.2.
See this video guide on how to install iPerf in the Windows operating system. See this video guide on testing iPerf.
Additionally, a firewall policy needs to be configured on FortiGate-101F between the source interface, port1, and the destination interface, wan1.
Firewall policy:
config firewall policy edit 2 set name "IPerf_Policy" set uuid 7f382096-3529-51f0-6ca8-91ae4870983c set srcintf "port1" <----- Source interface. set dstintf "wan1" <----- Destination interface. set action accept set srcaddr "all" set dstaddr "all" set schedule "always" set service "ALL" set logtraffic all set nat enable next
end
System interface details of port1:
config system interface edit "port1" set vdom "root" set ip 192.168.10.1 255.255.255.0 set allowaccess ping set type physical set device-identification enable set snmp-index 7 set speed auto next end
Hardware interface information of port1:
diagnose hardware deviceinfo nic port1 Description :FortiASIC NP6LITE Adapter Driver Name :FortiASIC NP6LITE Driver Board :101E lif id :6 lif oid :70 netdev oid :70 tx group :0 Current_HWaddr 90:6c:ac:b7:03:3e Permanent_HWaddr 90:6c:ac:b7:03:3e ========== Link Status ========== Admin :up netdev status :up autonego_setting:1 link_setting :1 speed_setting :10 duplex_setting :0 Speed :1000 <----- Link speed of port1 is 1 G. Duplex :Full link_status :Up ============ Counters =========== Rx Pkts :6671534 Rx Bytes :8982726821 Tx Pkts :4351736 Tx Bytes :5690150623 Host Rx Pkts :18177 Host Rx Bytes :2918745 Host Tx Pkts :8308 Host Tx Bytes :2911686 Host Tx dropped :0 FragTxCreate :0 FragTxOk :0 FragTxDrop :0
System interface details of wan1:
config system interface edit "wan1" set vdom "root" set ip 172.16.10.1 255.255.255.0 set allowaccess ping set type physical set device-identification enable set snmp-index 3 set speed auto next end
Hardware interface information of wan1:
diagnose hardware deviceinfo nic wan1 Description :FortiASIC NP6LITE Adapter Driver Name :FortiASIC NP6LITE Driver Board :101E lif id :2 lif oid :66 netdev oid :66 tx group :0 Current_HWaddr 90:6c:ac:b7:03:3a Permanent_HWaddr 90:6c:ac:b7:03:3a ========== Link Status ========== Admin :up netdev status :up autonego_setting:1 link_setting :1 speed_setting :10 duplex_setting :0 Speed :1000 <----- Link speed of wan1 is 1 G. Duplex :Full link_status :Up ============ Counters =========== Rx Pkts :2484426 Rx Bytes :2355309211 Tx Pkts :8994670 Tx Bytes :13007732692 Host Rx Pkts :21356 Host Rx Bytes :3236056 Host Tx Pkts :9832 Host Tx Bytes :3363034 Host Tx dropped :0 FragTxCreate :0 FragTxOk :0 FragTxDrop :0
Since the port1 and wan1 interfaces have a speed of 1GB, the iperf test between the two interfaces should be roughly around 1GB value.
In the command prompt on the client side, run this command:
iperf3.exe -c 172.16.10.2 -P 5
- -c: The device is the client.
- 172.16.10.2: server IP address.
- -P option: allows sending multiple streams of traffic between a client and server.
- 5: Number of multiple streams.
In the command prompt on the server side, run this command:
iperf3.exe -s
- s: The device is the server.
Windows Client:
C:\Users\Fortinet\Downloads\iperf3.1.1_32>iperf3.exe -c 172.16.10.2 -P 5 Connecting to host 172.16.10.2, port 5201 [ 4] local 192.168.10.2 port 55602 connected to 172.16.10.2 port 5201 [ 6] local 192.168.10.2 port 55603 connected to 172.16.10.2 port 5201 [ 8] local 192.168.10.2 port 55604 connected to 172.16.10.2 port 5201 [ 10] local 192.168.10.2 port 55605 connected to 172.16.10.2 port 5201 [ 12] local 192.168.10.2 port 55606 connected to 172.16.10.2 port 5201 [ ID] Interval Transfer Bandwidth [ 4] 0.00-1.00 sec 18.8 MBytes 157 Mbits/sec [ 6] 0.00-1.00 sec 33.9 MBytes 284 Mbits/sec [ 8] 0.00-1.00 sec 10.8 MBytes 90.2 Mbits/sec [ 10] 0.00-1.00 sec 33.0 MBytes 276 Mbits/sec [ 12] 0.00-1.00 sec 1.48 MBytes 12.4 Mbits/sec [SUM] 0.00-1.00 sec 97.9 MBytes 820 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 1.00-2.00 sec 3.08 MBytes 25.8 Mbits/sec [ 6] 1.00-2.00 sec 23.4 MBytes 196 Mbits/sec [ 8] 1.00-2.00 sec 27.3 MBytes 229 Mbits/sec [ 10] 1.00-2.00 sec 19.9 MBytes 167 Mbits/sec [ 12] 1.00-2.00 sec 28.4 MBytes 238 Mbits/sec [SUM] 1.00-2.00 sec 102 MBytes 857 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 2.00-3.00 sec 27.6 MBytes 232 Mbits/sec [ 6] 2.00-3.00 sec 36.6 MBytes 307 Mbits/sec [ 8] 2.00-3.00 sec 27.4 MBytes 230 Mbits/sec [ 10] 2.00-3.00 sec 10.1 MBytes 84.6 Mbits/sec [ 12] 2.00-3.00 sec 6.77 MBytes 56.8 Mbits/sec [SUM] 2.00-3.00 sec 109 MBytes 910 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 3.00-4.00 sec 13.7 MBytes 115 Mbits/sec [ 6] 3.00-4.00 sec 38.3 MBytes 322 Mbits/sec [ 8] 3.00-4.00 sec 24.1 MBytes 202 Mbits/sec [ 10] 3.00-4.00 sec 16.9 MBytes 141 Mbits/sec [ 12] 3.00-4.00 sec 10.3 MBytes 86.7 Mbits/sec [SUM] 3.00-4.00 sec 103 MBytes 866 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 4.00-5.00 sec 19.6 MBytes 165 Mbits/sec [ 6] 4.00-5.00 sec 12.1 MBytes 101 Mbits/sec [ 8] 4.00-5.00 sec 17.8 MBytes 150 Mbits/sec [ 10] 4.00-5.00 sec 26.2 MBytes 220 Mbits/sec [ 12] 4.00-5.00 sec 23.3 MBytes 195 Mbits/sec [SUM] 4.00-5.00 sec 99.0 MBytes 830 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 5.00-6.00 sec 17.5 MBytes 147 Mbits/sec [ 6] 5.00-6.00 sec 10.0 MBytes 84.1 Mbits/sec [ 8] 5.00-6.00 sec 37.1 MBytes 311 Mbits/sec [ 10] 5.00-6.00 sec 17.9 MBytes 150 Mbits/sec [ 12] 5.00-6.00 sec 21.8 MBytes 183 Mbits/sec [SUM] 5.00-6.00 sec 104 MBytes 875 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 6.00-7.00 sec 18.5 MBytes 155 Mbits/sec [ 6] 6.00-7.00 sec 31.3 MBytes 263 Mbits/sec [ 8] 6.00-7.00 sec 29.2 MBytes 245 Mbits/sec [ 10] 6.00-7.00 sec 20.2 MBytes 170 Mbits/sec [ 12] 6.00-7.00 sec 6.34 MBytes 53.2 Mbits/sec [SUM] 6.00-7.00 sec 106 MBytes 886 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 7.00-8.00 sec 11.1 MBytes 93.4 Mbits/sec [ 6] 7.00-8.00 sec 43.4 MBytes 364 Mbits/sec [ 8] 7.00-8.00 sec 35.8 MBytes 300 Mbits/sec [ 10] 7.00-8.00 sec 14.2 MBytes 119 Mbits/sec [ 12] 7.00-8.00 sec 1.72 MBytes 14.4 Mbits/sec [SUM] 7.00-8.00 sec 106 MBytes 891 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 8.00-9.00 sec 18.9 MBytes 159 Mbits/sec [ 6] 8.00-9.00 sec 38.1 MBytes 319 Mbits/sec [ 8] 8.00-9.00 sec 32.7 MBytes 274 Mbits/sec [ 10] 8.00-9.00 sec 11.9 MBytes 99.6 Mbits/sec [ 12] 8.00-9.00 sec 4.68 MBytes 39.2 Mbits/sec [SUM] 8.00-9.00 sec 106 MBytes 891 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 9.00-10.00 sec 28.0 MBytes 235 Mbits/sec [ 6] 9.00-10.00 sec 34.8 MBytes 292 Mbits/sec [ 8] 9.00-10.00 sec 31.3 MBytes 262 Mbits/sec [ 10] 9.00-10.00 sec 4.74 MBytes 39.8 Mbits/sec [ 12] 9.00-10.00 sec 7.38 MBytes 62.0 Mbits/sec [SUM] 9.00-10.00 sec 106 MBytes 891 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ ID] Interval Transfer Bandwidth [ 4] 0.00-10.00 sec 177 MBytes 148 Mbits/sec sender [ 4] 0.00-10.00 sec 177 MBytes 148 Mbits/sec receiver [ 6] 0.00-10.00 sec 302 MBytes 253 Mbits/sec sender [ 6] 0.00-10.00 sec 302 MBytes 253 Mbits/sec receiver [ 8] 0.00-10.00 sec 274 MBytes 229 Mbits/sec sender [ 8] 0.00-10.00 sec 274 MBytes 229 Mbits/sec receiver [ 10] 0.00-10.00 sec 175 MBytes 147 Mbits/sec sender [ 10] 0.00-10.00 sec 175 MBytes 147 Mbits/sec receiver [ 12] 0.00-10.00 sec 112 MBytes 94.0 Mbits/sec sender [ 12] 0.00-10.00 sec 112 MBytes 94.0 Mbits/sec receiver [SUM] 0.00-10.00 sec 1.02 GBytes 872 Mbits/sec sender <----- Client is trying to push 1 GB of traffic, but the network is getting 872 Mbps. [SUM] 0.00-10.00 sec 1.01 GBytes 872 Mbits/sec receiver <----- Client is trying to push 1 GB of traffic, but the network is getting 872 Mbps.
iperf Done.
Windows Server:
C:\Users\Fortinet\Downloads\iperf3.1.1_32>iperf3.exe -c 172.16.10.2 -P 5 Connecting to host 172.16.10.2, port 5201 [ 4] local 192.168.10.2 port 55602 connected to 172.16.10.2 port 5201 [ 6] local 192.168.10.2 port 55603 connected to 172.16.10.2 port 5201 [ 8] local 192.168.10.2 port 55604 connected to 172.16.10.2 port 5201 [ 10] local 192.168.10.2 port 55605 connected to 172.16.10.2 port 5201 [ 12] local 192.168.10.2 port 55606 connected to 172.16.10.2 port 5201 [ ID] Interval Transfer Bandwidth [ 4] 0.00-1.00 sec 18.8 MBytes 157 Mbits/sec [ 6] 0.00-1.00 sec 33.9 MBytes 284 Mbits/sec [ 8] 0.00-1.00 sec 10.8 MBytes 90.2 Mbits/sec [ 10] 0.00-1.00 sec 33.0 MBytes 276 Mbits/sec [ 12] 0.00-1.00 sec 1.48 MBytes 12.4 Mbits/sec [SUM] 0.00-1.00 sec 97.9 MBytes 820 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 1.00-2.00 sec 3.08 MBytes 25.8 Mbits/sec [ 6] 1.00-2.00 sec 23.4 MBytes 196 Mbits/sec [ 8] 1.00-2.00 sec 27.3 MBytes 229 Mbits/sec [ 10] 1.00-2.00 sec 19.9 MBytes 167 Mbits/sec [ 12] 1.00-2.00 sec 28.4 MBytes 238 Mbits/sec [SUM] 1.00-2.00 sec 102 MBytes 857 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 2.00-3.00 sec 27.6 MBytes 232 Mbits/sec [ 6] 2.00-3.00 sec 36.6 MBytes 307 Mbits/sec [ 8] 2.00-3.00 sec 27.4 MBytes 230 Mbits/sec [ 10] 2.00-3.00 sec 10.1 MBytes 84.6 Mbits/sec [ 12] 2.00-3.00 sec 6.77 MBytes 56.8 Mbits/sec [SUM] 2.00-3.00 sec 109 MBytes 910 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 3.00-4.00 sec 13.7 MBytes 115 Mbits/sec [ 6] 3.00-4.00 sec 38.3 MBytes 322 Mbits/sec [ 8] 3.00-4.00 sec 24.1 MBytes 202 Mbits/sec [ 10] 3.00-4.00 sec 16.9 MBytes 141 Mbits/sec [ 12] 3.00-4.00 sec 10.3 MBytes 86.7 Mbits/sec [SUM] 3.00-4.00 sec 103 MBytes 866 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 4.00-5.00 sec 19.6 MBytes 165 Mbits/sec [ 6] 4.00-5.00 sec 12.1 MBytes 101 Mbits/sec [ 8] 4.00-5.00 sec 17.8 MBytes 150 Mbits/sec [ 10] 4.00-5.00 sec 26.2 MBytes 220 Mbits/sec [ 12] 4.00-5.00 sec 23.3 MBytes 195 Mbits/sec [SUM] 4.00-5.00 sec 99.0 MBytes 830 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 5.00-6.00 sec 17.5 MBytes 147 Mbits/sec [ 6] 5.00-6.00 sec 10.0 MBytes 84.1 Mbits/sec [ 8] 5.00-6.00 sec 37.1 MBytes 311 Mbits/sec [ 10] 5.00-6.00 sec 17.9 MBytes 150 Mbits/sec [ 12] 5.00-6.00 sec 21.8 MBytes 183 Mbits/sec [SUM] 5.00-6.00 sec 104 MBytes 875 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 6.00-7.00 sec 18.5 MBytes 155 Mbits/sec [ 6] 6.00-7.00 sec 31.3 MBytes 263 Mbits/sec [ 8] 6.00-7.00 sec 29.2 MBytes 245 Mbits/sec [ 10] 6.00-7.00 sec 20.2 MBytes 170 Mbits/sec [ 12] 6.00-7.00 sec 6.34 MBytes 53.2 Mbits/sec [SUM] 6.00-7.00 sec 106 MBytes 886 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 7.00-8.00 sec 11.1 MBytes 93.4 Mbits/sec [ 6] 7.00-8.00 sec 43.4 MBytes 364 Mbits/sec [ 8] 7.00-8.00 sec 35.8 MBytes 300 Mbits/sec [ 10] 7.00-8.00 sec 14.2 MBytes 119 Mbits/sec [ 12] 7.00-8.00 sec 1.72 MBytes 14.4 Mbits/sec [SUM] 7.00-8.00 sec 106 MBytes 891 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 8.00-9.00 sec 18.9 MBytes 159 Mbits/sec [ 6] 8.00-9.00 sec 38.1 MBytes 319 Mbits/sec [ 8] 8.00-9.00 sec 32.7 MBytes 274 Mbits/sec [ 10] 8.00-9.00 sec 11.9 MBytes 99.6 Mbits/sec [ 12] 8.00-9.00 sec 4.68 MBytes 39.2 Mbits/sec [SUM] 8.00-9.00 sec 106 MBytes 891 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ 4] 9.00-10.00 sec 28.0 MBytes 235 Mbits/sec [ 6] 9.00-10.00 sec 34.8 MBytes 292 Mbits/sec [ 8] 9.00-10.00 sec 31.3 MBytes 262 Mbits/sec [ 10] 9.00-10.00 sec 4.74 MBytes 39.8 Mbits/sec [ 12] 9.00-10.00 sec 7.38 MBytes 62.0 Mbits/sec [SUM] 9.00-10.00 sec 106 MBytes 891 Mbits/sec - - - - - - - - - - - - - - - - - - - - - - - - - [ ID] Interval Transfer Bandwidth [ 4] 0.00-10.00 sec 177 MBytes 148 Mbits/sec sender [ 4] 0.00-10.00 sec 177 MBytes 148 Mbits/sec receiver [ 6] 0.00-10.00 sec 302 MBytes 253 Mbits/sec sender [ 6] 0.00-10.00 sec 302 MBytes 253 Mbits/sec receiver [ 8] 0.00-10.00 sec 274 MBytes 229 Mbits/sec sender [ 8] 0.00-10.00 sec 274 MBytes 229 Mbits/sec receiver [ 10] 0.00-10.00 sec 175 MBytes 147 Mbits/sec sender [ 10] 0.00-10.00 sec 175 MBytes 147 Mbits/sec receiver [ 12] 0.00-10.00 sec 112 MBytes 94.0 Mbits/sec sender [ 12] 0.00-10.00 sec 112 MBytes 94.0 Mbits/sec receiver [SUM] 0.00-10.00 sec 1.02 GBytes 872 Mbits/sec sender [SUM] 0.00-10.00 sec 1.01 GBytes 872 Mbits/sec receiver
iperf Done.
Additionally, receive bandwidth can be determined on a Windows client using the command:
iperf3.exe -c 172.16.10.2 -P 5 -R
- -c: The device is the client.
- 172.16.10.2: server IP address.
- -P option: allows sending multiple streams of traffic between a client and server.
- 5: Number of multiple streams.
- -R option: When the Windows client acts as a receiver.
Related article:
Troubleshooting Tip: Configure FortiGate as speed test (iperf) server
|