SWITCHING RESILIENCE
Spanning Tree and LACP Configuration Guide
How to build redundant Ethernet links without creating loops, mismatched port channels or a network that fails unpredictably.
Why this matters
Redundant cables between switches are valuable only when the control protocols understand them. Two parallel Layer 2 paths with no loop prevention can create a switching loop. Two links that are meant to form one LACP bundle but have different VLAN or speed settings may fail to join the same channel.
Spanning Tree protects Layer 2 from loops
Spanning Tree Protocol keeps redundant Layer 2 paths from forwarding at the same time when doing so would form a loop. The practical installer task is to make the root bridge intentional, keep edge ports clearly identified, and understand which uplinks are forwarding or blocking.
Edge ports
Ports connected to normal endpoints can often use an edge or PortFast-style feature so the endpoint reaches forwarding state quickly. That setting is not appropriate for unknown switch-to-switch links. Features such as BPDU Guard can be used on supported platforms to shut an edge port if bridge protocol traffic appears, helping catch accidental switch connections. Verify vendor behaviour before enabling globally.
LACP bundles physical links into one logical link
LACP lets multiple compatible Ethernet links operate as one logical port channel. Cisco's current EtherChannel guidance states that member ports should have compatible speed/duplex settings and, for Layer 2 trunks, the same VLAN and trunk parameters. An LACP bundle is not a substitute for configuration consistency.
Configuration sequence
- Confirm the two devices support the intended LACP mode and number of member links.
- Make each physical link work individually first.
- Match speed, duplex and physical media.
- Match access or trunk mode on all member ports.
- For trunks, match native VLAN behaviour and allowed VLAN list.
- Create the port channel and add member interfaces.
- Verify every intended member is active in the bundle.
- Check STP sees the logical port channel as expected.
- Disconnect one member and confirm traffic continues on the remaining member.
- Reconnect it and confirm it rejoins without errors.
A common misunderstanding about bandwidth
A two-link LACP bundle does not necessarily make one single flow run at twice the speed. Switches normally hash flows across member links using selected fields such as source/destination MAC or IP addresses. The main benefit is aggregate capacity across multiple flows plus link redundancy, subject to the vendor implementation.
What to look out for
- One member link in a suspended or individual state.
- Different allowed VLAN lists on member ports.
- One side configured as a static channel and the other expecting LACP.
- Different native VLANs.
- One member running at a different speed.
- A cable connected to the wrong switch port.
- STP root bridge moving unexpectedly after a new switch is installed.
Benefit to the client
Correctly configured redundancy can let a switch uplink survive a single cable, optic or port failure while keeping the network online. It also provides more aggregate uplink capacity for multiple simultaneous flows. The client gets resilience only if failover is tested rather than assumed.
Technical references
Training manual: redundant uplink without creating a loop
Cisco IOS XE example: LACP active bundle
interface range GigabitEthernet1/0/47-48
description LACP-to-Core
switchport mode trunk
switchport trunk allowed vlan 10,20,30,99
channel-group 1 mode active
interface Port-channel1
description LACP-to-Core
switchport mode trunk
switchport trunk allowed vlan 10,20,30,99
The exact platform syntax must be checked against the switch software release. Cisco documents LACP member consistency as important: member links need compatible speed, duplex and Layer 2 trunk settings.
Verification
show etherchannel summary
show interfaces port-channel 1
show spanning-tree
show interfaces trunk
Failover test
- Start continuous traffic across the uplink.
- Record the current active LACP members.
- Disconnect one member only.
- Confirm the logical port channel remains up and traffic continues.
- Reconnect the member and confirm it rejoins.
- Repeat with the other member if the maintenance window permits.
STP edge protection
For true endpoint-facing access ports, PortFast reduces the delay before forwarding. Cisco warns that PortFast should only be used toward end stations. BPDU Guard can disable a PortFast port if it receives a BPDU, which helps catch an accidental switch connection on an edge port.
interface GigabitEthernet1/0/10
switchport mode access
switchport access vlan 10
spanning-tree portfast
spanning-tree bpduguard enable
Common mistakes and why they fail
- One LACP member missing a VLAN: traffic can hash onto a member that cannot carry the VLAN.
- Static channel on one side, LACP on the other: the two ends do not agree on aggregation behaviour.
- PortFast on an inter-switch link: it can allow a loop to forward before STP protects the topology.
- No failover test: a visually complete bundle may contain only one operational member.