Skip to main content
RunBook Academy

← All labs in Linux

Lab · intermediate · ~45 min

Lab: Network baseline with iperf3 and ping

B · Nested virtualisationC · Simulation

Objectives

  • Capture bandwidth, latency, and loss baseline
  • Test TCP and UDP
  • Document the baseline

Prerequisites

This lab captures a network baseline using iperf3 and ping. By the end you will have the data to detect future network regressions.

Tasks

Task 1: Latency baseline

ping -c 100 <remote-host> | tee /tmp/latency.txt

Capture the average, min, max, and standard deviation.

Task 2: TCP bandwidth

iperf3 -c <remote-host> -t 30 -i 5 -J > /tmp/iperf-tcp.json

Capture: bitrate, retransmits.

Task 3: UDP at various bitrates

iperf3 -c <remote-host> -u -b 100M -t 30 -J > /tmp/iperf-udp-100m.json
iperf3 -c <remote-host> -u -b 500M -t 30 -J > /tmp/iperf-udp-500m.json
iperf3 -c <remote-host> -u -b 1G -t 30 -J > /tmp/iperf-udp-1g.json

For each: bitrate, jitter, packet loss.

Task 4: Reverse direction

iperf3 -c <remote-host> -R -t 30 -J > /tmp/iperf-reverse.json

Task 5: Parallel streams

iperf3 -c <remote-host> -P 4 -t 30 -J > /tmp/iperf-parallel.json

Task 6: Document

NETWORK BASELINE
================
Hosts: <host-a> to <host-b>
Date: 2026-08-09

Latency:
- min: 0.123 ms
- avg: 0.156 ms
- max: 0.234 ms
- mdev: 0.045 ms
- loss: 0%

TCP bandwidth (single stream):
- 935 Mbits/sec
- 0 retransmits

TCP bandwidth (4 parallel streams):
- 2.8 Gbits/sec aggregate

UDP at 100M:
- 100 Mbits/sec
- 0% loss
- jitter 0.012 ms

UDP at 1G:
- 850 Mbits/sec
- 8% loss
- jitter 0.234 ms

Reverse direction:
- 920 Mbits/sec
- 0 retransmits

Deliverables

  • · Network baseline for comparison
  • · iperf3 results in JSON

Verification status

Last reviewed
2026-08-09
Executed end to end
not yet run on hardware

The commands and configuration here have been reviewed against the verified software versions, but nobody has run this lab start to finish on a system meeting its prerequisites. Treat the Expected Outcome as the intended result rather than an observed one, and keep the Cleanup section to hand.