The LPIC-2 exam objective 201.2 — Advanced Network Configuration — demands you understand how Linux servers connect to networks in a reliable, high-performance way. This chapter tackles network bonding: the technique of combining multiple physical network cables into one virtual pipe that keeps your server online even when a cable fails. If you are studying for the LPIC-2, mastering bonding is essential because the exam frequently asks which bonding mode to use for redundancy versus performance, and traps you with subtle differences between the seven kernel modes.
Jump to a section
A simple way to picture Advanced Network Configuration and Bonding
Ever tried to water a faraway flower bed with a single, flimsy garden hose? You turn on the tap, the water dribbles out, the hose kinks, and the pressure is pathetic. If that hose gets cut by a spade, you have zero water until you fix it. Now imagine you run three separate hoses from the tap to that flower bed, binding them together every metre with cable ties. When you turn the tap on, water rushes through all three at once, giving you a powerful, soaking spray that reaches the back fence. If a car runs over one hose and splits it, the other two keep going. You do not lose water; you just get slightly less pressure. That is exactly what network bonding does for computer servers. Instead of relying on one network cable, you bundle two, three, or four physical Ethernet cables into a single logical connection. The operating system treats the bundle as one virtual network interface, spreading traffic across all cables and automatically rerouting around any single failure. In the IT world, the tap is the switch or router, the hoses are the Ethernet cables, and the cable ties are the bonding driver in the Linux kernel. Your server gets more bandwidth, fault tolerance, and no single point of failure.
Here is the clever bit: different bonding modes map to different real-life scenarios. In mode 0 (round-robin), water is sent down each hose in strict rotation — the first bucket goes down hose one, the second down hose two, the third down hose three. In mode 1 (active-backup), only one hose is ever used; the others lie slack until the active hose fails. That wastes capacity but guarantees no packet loss during a switchover, like having a spare tyre in your boot. Mode 4 (802.3ad link aggregation) is the most sophisticated: it treats all hoses as one fatter pipe, negotiating with the tap to ensure packets arrive in the correct order. For a beginner studying LPIC-2, the garden hose picture shows why bonding exists: reliability, speed, and efficient use of existing hardware without buying a faster switch.
Network bonding, also called link aggregation or NIC teaming, is a Linux kernel feature that lets you group several physical network interface controllers (NICs) — the hardware ports on the back of your server — into a single logical interface. To the applications running on the server, it looks like one connection with the combined speed of all the cables. If you have two 1 Gbps NICs bonded, the server sends and receives at up to 2 Gbps, and it keeps working if one cable is unplugged.
Before bonding existed, system administrators had two unattractive options. They could buy expensive, faster network hardware — say, one 10 Gbps NIC — or they could accept the risk that a single cable failure would take the server offline. Bonding solves both problems at the cost of extra cables and switch configuration. The kernel implements bonding through a kernel module called "bonding.ko", loaded with the command "modprobe bonding" or by configuring it in the file "/etc/modprobe.d/bonding.conf". Once loaded, you create a virtual interface — typically named bond0, bond1, and so on — and assign the physical NICs as slaves to that bond interface.
The behaviour of the bond is controlled by its mode parameter. The kernel supports seven modes, numbered 0 through 6. You must memorise at least the four tested by LPIC-2: modes 0, 1, 4, and 6.
Mode 0, balance-rr, stands for round-robin. It transmits packets in sequential order across the slave interfaces. The first packet goes out on the first slave, the second on the second slave, the third on the third slave, and then it cycles back. This provides load balancing and fault tolerance. The big drawback is that packets can arrive out of order on the receiving end, which can confuse some protocols. LPIC-2 loves to test that mode 0 requires switch support — the switch must be configured for link aggregation, or you will have network problems.
Mode 1, active-backup, is the simplest mode for fault tolerance. Only one NIC is active at any time. The other NICs sit idle, waiting for the active one to fail. If the active cable is disconnected or the NIC stops responding, the kernel automatically switches traffic to the next available slave. There is no load balancing. The IP address and Media Access Control (MAC) address stay the same, so there is no disruption to existing connections. This mode works with any standard switch; you do not need a switch that supports link aggregation. LPIC-2 exam questions often present a scenario where maximum reliability with zero performance gain is needed — that is mode 1.
Mode 4, 802.3ad, also called IEEE 802.3ad dynamic link aggregation, is the most complex mode. It uses the Link Aggregation Control Protocol (LACP) to negotiate with the switch to combine ports into a single logical trunk. Both the server and the switch must be configured correctly. LACP packets are exchanged to verify that both sides agree on which ports are part of the bond. Mode 4 provides both load balancing and fault tolerance. The load balancing is based on a hash algorithm — typically a hash of the source and destination MAC addresses or IP addresses — that ensures traffic from the same conversation always uses the same slave, preventing packet reordering. LPIC-2 tests your understanding that mode 4 requires a switch that supports LACP, and that you must configure "lacp_rate" parameters to control how often LACP packets are sent.
Mode 6, balance-alb, stands for adaptive load balancing. It does not require any special switch configuration. It achieves load balancing by dynamically adjusting the MAC addresses of the NICs and by sending Address Resolution Protocol (ARP) replies to redirect incoming traffic to the current transmitting slave. This mode provides both load balancing and fault tolerance. LPIC-2 tests that mode 6 is the only bonding mode that can send and receive load balancing without switch support, but it is also the most CPU-intensive because the kernel software has to handle the MAC address rewriting.
To make a bond interface persistent across reboots on most Linux distributions, you edit network configuration files. On Debian-based systems (like Ubuntu), you edit "/etc/network/interfaces" to define a bond interface with slaves, mode, and other options such as "miimon" (monitoring interval in milliseconds). On Red Hat-based systems (like CentOS or RHEL), you create or edit files in "/etc/sysconfig/network-scripts/" — for example, "ifcfg-bond0" and "ifcfg-eth0" with the "MASTER=bond0" and "SLAVE=yes" directives. The key parameters you need to know for the exam are:
miimon: how often (in milliseconds) the bond driver checks the link status of each slave. A common value is 100 (check every 100ms).
updelay: a delay (in milliseconds) before a link is considered up after it becomes active, to prevent flapping.
downdelay: a delay before a link is considered down after it stops responding.
lacp_rate: only used in mode 4; specifies how often LACP packets are sent. "slow" (every 30 seconds) or "fast" (every 1 second).
A common beginner mistake is forgetting to load the bonding module before configuring interfaces. If you reboot and the bond interface fails to come up, it is often because the bonding module is not listed in "/etc/modules" or a similar kernel module configuration file. LPIC-2 expects you to know how to load the module with "modprobe bonding" and to ensure it loads automatically.
Bonding is not the same as bridging or routing. Bridging connects two network segments at layer 2 (data link layer) to form a single network. Bridging and bonding are sometimes confused. Bonding combines multiple links into one logical link for redundancy and bandwidth; bridging combines multiple networks into one logical network. The exam may present a scenario where you need to decide which to use. Bonding is purely about the physical link between your server and the switch. It does not change the network topology — it just makes the link faster and more reliable.
Identify the Network Hardware
List the physical NICs available on your server using 'ip link show' or 'ifconfig -a'. Note their names (eth0, eth1, ens33, etc.) and speed. This determines how many slaves you can bond and whether bonding is worthwhile (bonding two 100 Mbps links gives 200 Mbps aggregate, but buying a 1 Gbps card may be cheaper).
Decide the Bonding Mode
Choose the mode based on your switch capabilities and requirements. If you need fault tolerance with no switch support, pick mode 1. If you need both performance and fault tolerance without switch config, pick mode 6. If you have a managed switch with LACP, pick mode 4. This decision affects every following step.
Configure the Bonding Module
Load the bonding kernel module with 'modprobe bonding' and optionally set default options in /etc/modprobe.d/bonding.conf. Include the mode and miimon. For example: 'options bonding mode=6 miimon=100'. Without this step, the bond interface will not exist at boot.
Create the Bond Interface Configuration
On Red Hat systems, create /etc/sysconfig/network-scripts/ifcfg-bond0 with the IP address, netmask, gateway, and bonding options. On Debian systems, edit /etc/network/interfaces to define the bond0 interface with bond-mode, bond-miimon, and bond-slaves.
Configure the Slave Interfaces
For each physical NIC (eth0, eth1), edit its configuration file to add 'MASTER=bond0' and 'SLAVE=yes' (Red Hat) or 'bond-master bond0' (Debian). Do not assign an IP address to slaves; they inherit from bond0. Omitting this means the NICs are not part of the bond.
Activate the Bond and Test
Restart the network service or bring the interfaces down and up. Verify with 'ip link show bond0' and 'cat /proc/net/bonding/bond0'. Test fault tolerance by unplugging a cable while pinging the bond IP. A few lost packets are normal; complete disconnection means misconfiguration.
Imagine you are the sole IT administrator for a mid-sized e-commerce company. The company runs its online shop on a single Linux server in the office. The server has two NIC ports, each connected to a different network switch. The switches themselves are connected to the company's router and then to the internet. Currently, only one NIC is active. The boss asks: why does the website sometimes become unreachable when a cleaner accidentally bumps the cable? And can we make it faster without buying a 10-gigabit switch?
Your solution is network bonding. Here is exactly what you do:
First, you check the current network configuration. You run "ip link show" and see eth0 and eth1 as the two physical interfaces. Both are 1 Gbps. You have an old switch that does not support LACP, so you cannot use mode 4. You also cannot trust that both cables will always be connected, so you need fault tolerance. But the boss also wants some bandwidth improvement. You decide to use mode 6 (balance-alb) because it works with any switch and gives both load balancing and fault tolerance.
You install the bonding modules. You edit "/etc/modprobe.d/bonding.conf" and add a line to load the bonding module with the options you need: "alias bond0 bonding" and "options bonding miimon=100 mode=6". On a Red Hat system, you then create the bond0 configuration file "/etc/sysconfig/network-scripts/ifcfg-bond0" with:
DEVICE=bond0
BOOTPROTO=static
IPADDR=192.168.1.100
NETMASK=255.255.255.0
GATEWAY=192.168.1.1
ONBOOT=yes
BONDING_OPTS="mode=6 miimon=100"
Next, you edit the slave interface files. For eth0, you create or modify "ifcfg-eth0" to contain:
DEVICE=eth0
MASTER=bond0
SLAVE=yes
ONBOOT=yes
You do the same for eth1. You then restart the network service with "systemctl restart network" (or "ifdown eth0; ifdown eth1; ifup bond0" on older systems). Once the bond is up, you verify with "ip link show bond0". You should see that the bond0 interface has the MAC address of the first slave and is in "UP" state. You also check the bonding status by reading "/proc/net/bonding/bond0". This pseudo-file shows the active slaves, the mode, and the link status of each slave. It is the first place you look when troubleshooting.
Now test fault tolerance. While a colleague pings the server from their workstation, you unplug eth0. The ping continues with one or two lost packets — the bond switches to eth1. You plug eth0 back in and the bond re-adds it automatically (depending on the mode and miimon). The website remains available. The boss is happy because the server now has redundant network paths and slightly better throughput.
Later, the company grows and buys a managed switch that supports 802.3ad LACP. You upgrade the bond to mode 4 for better performance and standardised load balancing. You reconfigure the switch ports to be in a LACP trunk group. You update the bonding configuration on the server to "mode=4 lacp_rate=fast miimon=100". You also configure the "xmit_hash_policy" parameter to control how packets are distributed; the default "layer2" hash is fine for basic setups, but you might switch to "layer3+4" for better distribution across many connections.
As an IT professional, you will use bonding in virtualisation environments (combining NICs from the host to the hypervisor), storage networks (bonding iSCSI connections), and any production server that cannot afford downtime. The tools you use daily include:
ip command (check interface status)
ethtool (query and change NIC settings)
/proc/net/bonding/bond0 (live bonding status)
network configuration files
/etc/modprobe.d/ (to load bonding module)
switch CLI or web interface (to configure LACP)
LPIC-2 exam 201.2 tests network bonding heavily. You will see at least two or three questions on bonding modes, configuration files, and troubleshooting commands. The exam does not ask you about every mode — it focuses on modes 0, 1, 4, and 6. Here is exactly what you must know.
First, memorise the mode numbers and their names:
Mode 0 = balance-rr (round-robin)
Mode 1 = active-backup (fault tolerance only, no load balancing)
Mode 4 = 802.3ad (LACP, requires switch support)
Mode 6 = balance-alb (adaptive load balancing, no switch support needed)
The exam loves to ask: "Which bonding mode provides fault tolerance but no load balancing?" Answer: Mode 1. "Which mode requires a switch that supports 802.3ad?" Answer: Mode 4. "Which mode distributes packets in round-robin fashion?" Answer: Mode 0.
Trap alert: The exam may present a scenario where you have two NICs and a switch that does not support aggregation. They ask for a mode that provides both load balancing and fault tolerance. Most beginners pick mode 4, but that requires switch support. The correct answer is mode 6 (balance-alb), which does not require switch support. Another trap: they ask for a mode that requires the switch to be configured for link aggregation. The correct answer is mode 0 (balance-rr) also requires switch support unless you are using a crossover cable or a specific topology — but in a typical switched network, mode 0 and mode 4 both need switch configuration. Mode 0 needs the switch ports to be in the same broadcast domain and often requires manual static aggregation. Mode 4 uses LACP.
They will also test configuration file syntax. On RHEL/CentOS, you must know that "MASTER=bond0" and "SLAVE=yes" go into the slave interface file. On Debian, you use "bond-slaves none" and "bond-mode" in "interfaces". The exam sometimes gives you a configuration snippet with a typo — for instance, "MASTER=bond0" typed as "MASTER=bond0" correctly but "SLAVE=yes" misspelled as "SLAVE=Y" (uppercase Y). The correct syntax is lowercase "yes".
Another frequent exam topic: the /proc/net/bonding/bond0 file. They ask: "What file shows the current bonding status including active slave and link failures?" The answer is /proc/net/bonding/bond0. They may ask what "MII Status: up" means — it means the link is physically active.
They also test the bonding module loading. They might ask: "What command loads the bonding module?" Answer: "modprobe bonding". Or: "What file ensures the bonding module is loaded at boot?" Answer: /etc/modprobe.d/bonding.conf or /etc/modules (depending on distribution).
Key definitions to memorise:
MII: Media Independent Interface, the standard for connecting Ethernet MAC to the PHY transceiver.
LACP: Link Aggregation Control Protocol, part of IEEE 802.3ad.
miimon: Monitoring interval in milliseconds.
updelay / downdelay: Timers to prevent flapping.
Active-backup: Only one NIC transmits.
Balance-alb: Adapts MAC addresses for load balancing.
The exam can also present a troubleshooting scenario: "A server with mode 4 bonding is experiencing packet loss. What is the likely cause?" The answer: The switch ports are not configured as a LACP trunk, or the LACP negotiation is not happening because of mismatched settings (e.g., one side has "active" and the other "passive"). Another scenario: "A bond interface fails to come up after reboot. What is the cause?" The bonding module is not loaded at boot — check /etc/modules or modprobe configuration.
Finally, they may test the difference between bonding and other network configurations like bridging. They might ask: "Which technology aggregates multiple network links into a single logical link for redundancy and bandwidth?" Answer: Bonding. And: "Which technology connects two separate networks at layer 2?" Answer: Bridging. Do not mix them up.
Network bonding combines multiple physical NICs into one logical interface for increased bandwidth and fault tolerance.
Mode 1 (active-backup) provides fault tolerance only and works with any switch.
Mode 4 (802.3ad LACP) requires a switch that supports LACP and provides both load balancing and fault tolerance.
Mode 6 (balance-alb) provides load balancing and fault tolerance without switch support but uses more CPU.
The miimon parameter sets how often the kernel checks link status, typically every 100 milliseconds.
Always configure the bonding module to load at boot to prevent bond interfaces from failing after a reboot.
These come up on the exam all the time. Here's how to tell them apart.
Mode 0 balance-rr
Transmits packets in round-robin order across all slaves
Provides load balancing and fault tolerance
Requires switch support to avoid packet looping
Mode 1 active-backup
Only one slave active at a time; others are standby
Provides fault tolerance only, no load balancing
Works with any standard switch without special configuration
Mode 4 802.3ad LACP
Uses dynamic LACP negotiation with the switch
Requires a managed switch that supports 802.3ad
Provides both load balancing and fault tolerance
Mode 6 balance-alb
Does not require any switch support
Achieves load balancing by rewriting MAC addresses
Higher CPU usage due to software MAC manipulation
Bonding
Combines multiple physical links into one logical link
Operates mainly at layer 2 but focus is on link aggregation
Increases bandwidth and provides redundancy for the server-switch connection
Bridging
Connects multiple network segments into one broadcast domain
Operates at layer 2, forwarding frames between ports based on MAC addresses
Used to create virtual networks (e.g., KVM bridges) not for link aggregation
Mistake
Bonding always doubles your bandwidth for every type of traffic.
Correct
Bonding increases aggregate throughput across multiple concurrent connections, but a single TCP connection may not see full doubling because load balancing is per-packet or per-flow based on hashing.
Beginners think adding a second 1 Gbps link gives 2 Gbps for a single user download. In practice, a single TCP stream usually hits one slave due to hash-based distribution, so max per-stream throughput stays at 1 Gbps.
Mistake
Mode 0 (balance-rr) works with any switch without configuration.
Correct
Mode 0 requires switch configuration to allow the ports to be in the same link aggregation group, otherwise the switch may send traffic to only one port or cause packet duplication and loops.
Round-robin transmits packets from different slaves, confusing the switch's MAC address table because the same MAC seems to come from multiple ports. The switch must be configured for static link aggregation.
Mistake
Bonding and bridging are the same thing because both combine interfaces.
Correct
Bonding combines physical links into one logical link for redundancy and bandwidth; bridging combines separate networks into one broadcast domain at layer 2, forwarding frames between ports.
Both involve multiple interfaces, so beginners conflate them. Bonding is for link aggregation to a single switch; bridging is for connecting different segments like virtual bridges in KVM.
Mistake
If a bond interface is set to mode 1 (active-backup), you can use both NICs simultaneously by sending different IP addresses to each.
Correct
In active-backup mode, only one NIC is active at a time. The other is standby. You cannot use both NICs simultaneously; the IP address is assigned to the bond interface, not the slave NICs.
Beginners think they can cheat active-backup by assigning IPs to slaves, but the kernel prevents that. The bond interface manages all traffic; slave NICs have no separate IP configuration in a bond.
Mistake
LACP (mode 4) is always better than other modes because it is the most advanced.
Correct
LACP is better for performance and standardisation in managed environments, but it requires switch support and correct configuration on both ends. For simple fault tolerance, mode 1 is more reliable and simpler.
Newcomers assume complex equals better. Mode 1 works on any switch and guarantees zero packet loss during failover for active TCP connections, which LACP cannot guarantee because it may reorder packets during re-delivery.
Reveal each answer, then mark whether you got it right. Score 60%+ to unlock the next chapter.
No, standard Cat5e or Cat6 Ethernet cables work fine. Bonding is a software configuration; the hardware cables just need to connect the server NICs to the switch ports.
Technically yes, but it causes problems. The faster NIC will be limited to the speed of the slower one in many modes, and load balancing becomes uneven. Best practice is to use identical NICs.
Bonding and teaming are similar but not identical. Teaming is a newer Linux feature using teamd daemon, offering more flexibility. LPIC-2 focuses on the older bonding module (kernel bonding). Some distributions now prefer teamd, but the exam tests bonding as defined in the objectives.
Run 'cat /proc/net/bonding/bond0'. It shows mode, slave status, link failures, and MII status. Replace bond0 with your bond interface name if different.
The bonding module likely did not load automatically. Check /etc/modules (Debian) or /etc/modprobe.d/bonding.conf (RHEL) to ensure the module is listed. Also verify that the slave configuration files contain 'MASTER=bond0' and 'SLAVE=yes'.
Both are monitoring methods. miimon checks the physical link carrier by reading MII registers; it is fast and reliable. arp_interval sends ARP requests to a target IP to verify connectivity up to layer 3; it is more thorough but can be fooled by routing issues. LPIC-2 only tests miimon.
You've finished Advanced Network Configuration and Bonding. Continue through the LPIC-2 study guide to build a complete picture of the exam.
Done with this chapter?