Linux for network engineers lab 12 of 14

Performance: iperf3, netem, MTU and PMTUD

You measure a link with iperf3, then make it worse on purpose with netem and tbf to see how delay, rate and loss each change TCP. Then you shrink the MTU, build a PMTUD black hole and fix it with MSS clamping.

Run this lab

It needs Lite: its 4 nodes are set to 4 vCPU and 3,072 MB in total. That fits the free demo too.

In your workspace: Shared, then Linux for network engineers guided labs, then 12 - Performance - iperf3 netem MTU and PMTUD

Try it free for 30 minutesRun it on Lite from £3 a day

The free demo needs no card and no email. Every lab plan includes every guided lab.

Level
Advanced
Time
About 80 minutes
Nodes need
4 vCPU, 3,072 MB
Smallest plan
Lite

The scenario

Kestrel is moving the Scunthorpe depot on to a slower link with a tunnel in the path, and the managers want to know what users will feel. There's no budget for a test circuit, but two Linux routers can pretend to be any WAN you like. You'll measure a clean path, then add delay, a rate limit and loss, and then shrink the MTU to see what breaks.

DeviceInterfaceAddressRole
WS1eth010.12.1.50/24test client
GW1eth0, eth110.12.1.1/24, 10.12.0.1/30router; impairs traffic leaving eth1
GW2eth0, eth110.12.0.2/30, 10.12.2.1/24router
WS2eth010.12.2.50/24iperf3 server, web server with small.txt and big.bin
DeviceRunsHow to log in
WS1, WS2Ubuntu 22.04 desktop containerIts console is a remote desktop: root / eve. Open a terminal there.
GW1, GW2Alpine Linux 3.16 with iptables and iproute2Opens on a menu: press 5, then Enter, for a root shell.

What you’ll practise

  • Measure TCP and UDP with iperf3
  • Add delay and loss with netem and shape with tbf
  • Work out the bandwidth-delay product and see the window limit
  • Find a path MTU with DF pings
  • Recognise and fix a PMTUD black hole with MSS clamping

The tasks

  1. Start the Linux nodes
  2. Measure the baseline
  3. Add delay and meet the bandwidth-delay product
  4. Shape the rate
  5. Add a little loss
  6. Find the path MTU
  7. Fall into a black hole and climb out

The Lab Tasks pane has the scenario, these tasks, the checks to run, hints and the full solution.

Topology and devices

The network as it opens in EVE-NG, drawn from the lab’s own canvas, and the image each node runs.

Topology of Performance - iperf3 netem MTU and PMTUD4 nodes, 3 links. Every link is listed as text below the diagram.WS1WS2GW1GW2eth0eth0eth1eth0eth1eth0
4 nodes, with the interface names each link uses. On a narrow screen, scroll the diagram sideways.
Nodes in Performance: iperf3, netem, MTU and PMTUD, with the image each runs and the vCPU and RAM it’s set to
NodeDeviceImage in Add NodeSet to
WS1EVE-NG GUI server (Docker)eve-gui-server:latest1 vCPU, 1,024 MB
WS2EVE-NG GUI server (Docker)eve-gui-server:latest1 vCPU, 1,024 MB
GW1Alpine WAN emulatorclbalpinewanem-alpine-3-16-2-wanem1 vCPU, 512 MB
GW2Alpine WAN emulatorclbalpinewanem-alpine-3-16-2-wanem1 vCPU, 512 MB

How to open this lab

  1. Sign in to your workspace at lab.cloudlabbox.com.

  2. In File Manager, open Shared, then the folder Linux for network engineers guided labs.

  3. Open 12 - Performance - iperf3 netem MTU and PMTUD and start its nodes, then open Lab Tasks for the scenario and the steps.

The lab is read-only. You can start the nodes and configure the devices, but changes to the topology can’t be saved. To change it, rebuild it in your own folder.

More Linux for network engineers labs

All Linux for network engineers labs

CloudLabBox is independent of Cisco, CompTIA, the Linux Foundation and the Linux Professional Institute. The lab follows exam topics and isn’t vendor training material; vendor names identify the exams and the images in the workspace.