- Alpine linux edge using qemu emulation
- Windows on Github Actions runners for x86_64 using a custom Cywgin installer script
- MacOS on Github Actions runners for amd64 (mmacos-13) and arm64 (macos-14) with static openssl and iperf libraries.
Linux:
- Arch:
amd64
arm32v6
arm32v7
arm64v8
i386
ppc64le
riscv64
s390x
- Docker: yes
- Static binaries: yes
Windows:
- Arch:
amd64
- Docker: no
- Static binaries: yes
MacOS:
- Arch:
amd64
arm64
- Docker: no
- Static binaries: yes
Note
Windows and MacOS binaries are not fully static in terms of their dependency and cygwin1.dll
(Windows) libSystem.B.dylib
(MasOS).
They are statically linked with libcrypo.a
libssl.a
(openssl) and iperf3.a
(iperf3) so there should be no other system dependency required to run them on the target hosts.
On Windows openssl is built from Github source to get static libs and on MacOS we get them from the brew cellar installation of openssl@3
Static binaries for Linux and Windows are available here: https://github.com/userdocs/iperf3-static/releases/latest
Example:
curl -sLo- iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-amd64
chmod +x iperf3
iperf3 --version
Multiarch Docker images are available via https://github.com/users/userdocs/packages/container/package/iperf3-static
Example:
docker pull ghcr.io/userdocs/iperf3-static:latest
To used the image dynamically
docker run -it ghcr.io/userdocs/iperf3-static:latest iperf3 --version
Expand for details
Alpine Arch | Docker platform arch | Source of Build Dockers | ghcr.io image |
---|---|---|---|
armhf | linux/arm/v6 | https://hub.docker.com/r/arm32v6/alpine | arm32v6/alpine:edge |
armv7 | linux/arm/v7 | https://hub.docker.com/r/arm32v7/alpine | arm32v7/alpine:edge |
aarch64 | linux/arm64 | https://hub.docker.com/r/arm64v8/alpine | arm64v8/alpine:edge |
ppc64le | linux/ppc64le | https://hub.docker.com/r/ppc64le/alpine | ppc64le/alpine:edge |
s390x | linux/s390x | https://hub.docker.com/r/s390x/alpine | s390x/alpine:edge |
riscv64 | linux/riscv64 | https://hub.docker.com/r/riscv64/alpine | riscv64/alpine:edge |
x86 | linux/i386 | https://hub.docker.com/r/i386/alpine | i386/alpine:edge |
x86_64 | linux/amd64 | https://hub.docker.com/r/amd64/alpine | amd64/alpine:edge |
Expand for details
Static Cygwin builds created via cygwin64 using this custom installer
https://github.com/userdocs/iperf3-static/blob/master/cygwin-installer.cmd
Expand for details
apk add build-base pkgconf autoconf automake curl libtool git perl openssl-libs-static openssl-dev linux-headers
apt install -y build-essential pkg-config automake libtool libssl-dev git perl
Without openssl
automake,gcc-core,gcc-g++,git,libtool,make,pkg-config
With openssl
automake,gcc-core,gcc-g++,git,libtool,make,pkg-config,libssl-devel,zlib-devel
Clone the git repo - linux + Cygwin
git clone https://github.com/esnet/iperf.git ~/iperf3 && cd ~/iperf3
Bootstrap - If you cloned the repo
./bootstrap.sh
Configure - linux + Cygwin
Note: Cygwin requires requires compiling openssl and zlib static libs to link statically. Otherwise you compile dynamically
Static
./configure --disable-shared --enable-static-bin --prefix=$HOME
Dynamic
./configure --prefix=$HOME
Cygwin openssl requires compiling openssl and zlib
Build - linux + Cygwin
make -j$(nproc)
make install
ldd ~/bin/iperf3
Use this command to check the version.
~/bin/iperf3 -v
Will show something like this.
iperf 3.10.1 (cJSON 1.7.13)
Optional features available: CPU affinity setting, IPv6 flow label, TCP congestion algorithm setting, sendfile / zerocopy, socket pacing, authentication, bind to device, support IPv4 don't fragment
Download and install to the bin directory of your local user (for root this may not be in the $PATH
)
Pick the platform URL you need:
i386 / x86
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-i386
chmod 700 ~/bin/iperf3
amd64
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-amd64
chmod 700 ~/bin/iperf3
arm32v6
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-arm32v6
chmod 700 ~/bin/iperf3
arm32v7
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-arm32v7
chmod 700 ~/bin/iperf3
aarch64 / arm64
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-arm64v8
chmod 700 ~/bin/iperf3
ppc64le
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-ppc64le
chmod 700 ~/bin/iperf3
s390x
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-s390x
chmod 700 ~/bin/iperf3
Windows builds required being bundled with Cygwin dlls to work so these are not single static binaries. They have a directory structure like this.
iperf3.exe
cygwin1.dll
Windows x64 no openssl
https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-amd64-win.zip
Windows x64 with openssl
https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-amd64-win-openssl.zip
Check the version:
~/bin/iperf3 -v
Expand for details
amd64 macos-13 intel
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-amd64-osx-13
chmod 700 ~/bin/iperf3
arm64 macos-14 apple M1
mkdir -p ~/bin && source ~/.profile
wget -qO ~/bin/iperf3 https://github.com/userdocs/iperf3-static/releases/latest/download/iperf3-arm64-osx-14
chmod 700 ~/bin/iperf3
Expand for details
Binaries built from the release of 3.17.1+
use actions/attest-build-provenance
Verify the integrity and provenance of an artifact using its associated cryptographically signed attestations.
https://cli.github.com/manual/gh_attestation_verify
For example:
gh attestation verify iperf3-amd64 -o userdocs
Will give you this result for the release-5.0.0_v2.0.10
revision 1
binary.
Loaded digest sha256:84f9851d0647d3d618c66d64cac10ed1eb37583b3aaf3bb0baac88bf446fb10a for file://iperf3-amd64
Loaded 6 attestations from GitHub API
✓ Verification succeeded!
sha256:84f9851d0647d3d618c66d64cac10ed1eb37583b3aaf3bb0baac88bf446fb10a was attested by:
REPO PREDICATE_TYPE WORKFLOW
userdocs/iperf3-static https://slsa.dev/provenance/v1 .github/workflows/alpine_multi.yml@refs/heads/master
Expand for details
All binaries and dlls are scanned by virus total and the results uploaded using this action
https://github.com/crazy-max/ghaction-virustotal
The results url is uploaded to the release body and you can see them here https://github.com/userdocs/iperf3-static/releases/latest
Expand for details
Other contributions have helped inspire the creation of a GitHub action for a Windows build and release.
www.neowin.net via budman
https://github.com/ar51an/iperf3-win-builds via cryptanalyst
Expand for details
Step 1: Fork the repo: https://github.com/userdocs/iperf3-static/fork
Step 2: Under the repo /settings/secrets/actions
you will need to set a the VT_API_KEY
using your
You can find it here if you have created an account: https://www.virustotal.com/gui/my-apikey
Step 3: Under the Actions tab, enable workflows. The check_new_release.yml
defaults to a scheduled check but can be run manually.
iperf3-static/.github/workflows/check_new_release.yml
Lines 11 to 12 in 0571ce6
https://github.com/R0GGER/public-iperf3-servers?tab=readme-ov-file#servers-per-continent
Linux one liner for an example output of ./iperf3 -c speedtest.ip-projects.de
for a random Europe server
./$(curl -sL https://db.iperf3serverlist.net/api/v1/db/public/shared-view/b111407c-43c4-48af-a828-301b698064a3/rows/export/csv | awk -F, 'NR>1 { print $1 }' | shuf -n1)