This post is about installing iPerf2 from source. The target machine used as an example is an Apple MacBook Pro 2023 with an Apple M2 Pro chip.

Table of Contents



Install dependencies with Homebrew:

brew install gcc automake

Download source

Go to, click on the Files tab, and download the .tar.gz file for your desired version.

In this post, I used 2.1.9

Put it somewhere on your machine like ~/Downloads.

Extract and enter the directory using tar -xvf <archive> like so:

cd ~/Downloads
tar -xvf iperf-2.1.9.tar.gz
cd iperf-2.1.9


If you’ve not already entered the directory from the previous step, do so now.

  1. Run ./configure to configure the for our machine:
  1. Compile iPerf2:
  1. Install iPerf2
sudo make install


Run iperf -v:

iperf -v
iperf version 2.1.9 (14 March 2023) pthreads



↑ Top