This article explains how to configure link aggregation on the UniFi Switch devices, as well as what considerations should be taken into account when configuring a link aggregation group.
Table of Contents
- Network Diagram
- Steps: How to Configure Link Aggregation Groups
- Related Articles
Configuring the UniFi switches with a link aggregation group (LAG) allows a UniFi Administrator to be able to expand the maximum throughput on a network path.
Link Aggregation Control Protocol (LACP) is a dynamically negotiated protocol that ensures that the LAG configuration is compatible and viable on each endpoint. LACP also provides the ability for the load balancing to failover in the event that one of the bundled links were to fail.
Steps: How to Configure Link Aggregation Groups
- Navigate to the Devices section in the UniFi Network Controller and click on the switch to open the Properties Panel.
- In the Properties Panel, go to the Ports section and select a port that will participate in the link aggregation group by selecting Edit (pencil icon) when hovering over it.
- Click Profile Overrides to expand section.
- Under Operations, select Aggregate. This will expose some Aggregate options.
- Under the Aggregate Ports input which ports to include in the LAG.
- Take note of the warning about order of operations when enabling the link aggregation group.
- Both LAGs on the connecting devices must have the same port profile. Port numbers do not have to match.
- Up to six ports may be configured in the LAG. These ports must be sequential in number.
- Up to six individual LAGs can be configured.
- Static LAG configurations are not supported. LACP (802.3ad) only.
- No Multi-chassis Link Aggregation Group (MLAG).
Spanning Tree Protocol (STP)
When defining a LAG it is important to understand that the STP port cost is divided by however many active links are participating in the LAG.
|Number of Ports||LAG STP Port Cost|
|4x 1Gbps ports (20,000 original port cost)||5,000|
|2x 10Gbps ports (2,000 original port cost)||1,000|
A LAG may alter the best path based on the port cost to the root bridge. Be certain that an administratively-defined root bridge is selected.
Order of Operations
When enabling link aggregation between UniFi switches it is important to retain access to the controller for provisioning to take place. When enabling the LAG on the devices be certain that configuration changes are first done on the downstream switch, and then on the upstream switch.
- Hashing based on Source/Destination MAC, VLAN, EtherType, and incoming port associated with the packet
Throughput testing with one host to another single host will not show improvements. The hashing algorithm that is used for LACP does not split data streams on single host-to-host connections. To see improvements in throughput multiple hosts would have to be passing traffic at the same time.
- View counters on LAG:
show interface lag #
- View LACP partners on all ports:
show lacp partner all