19 Link bonding
Two cables bonded into one interface. Unplug the active one and the bond keeps going.
What you practice
- Bonds in netplan (
active-backup, MII monitoring) - Failover when a cable is unplugged
Topology
| Node | Image | CPUs / memory | Addresses | Role |
|---|---|---|---|---|
a | debian-13 | 1 / 1GiB | mgmt 10.119.0.11 | Bond end A |
b | debian-13 | 1 / 1GiB | mgmt 10.119.0.12 | Bond end B |
Before you start
bash
vz image pull disk debian-13Run it
bash
cd examples/19-bonding
vz validate
vz up
vz node ls
ssh lab@10.119.0.11 # password: labTry it
bash
ssh lab@10.119.0.11 'cat /proc/net/bonding/bond0'
ssh lab@10.119.0.11 'ping -D 172.16.19.2' # leave running
vz link down l1 # the bond moves to l2
ssh lab@10.119.0.11 'grep "Active Slave" /proc/net/bonding/bond0'
vz link up l1Notes
Every node also has a mgmt NIC on a NAT switch: out-of-band access from the Mac and package downloads. The exercise traffic stays on the links.
Clean up
bash
vz down
vz destroy --yes # deletes the overlays and state of this lab