Spanning Tree Configuration in Omada SDN Controller Mode
Spanning Tree Protocol (STP) is a Layer 2 Protocol that prevents loops in the network. As shown below, STP helps to:
- Block specific ports of the switches to build a loop-free topology.
- Detect topology changes and automatically generate a new loop-free topology.
Rapid Spanning Tree (RSTP) provides the same functionality as STP with much faster spanning tree convergence and is, therefore, more recommended.
TP-Link JetStream switches support STP/RSTP, this article will describe how to configure them via Omada SDN Controller. For a detailed description of relative concepts, working mechanism, the configuration in Standalone mode, etc., please refer to the Spanning Tree Configuration Guide.
Note:
1. If not explicitly stated, STP in the following refers to both STP and RSTP.
2. If one of the STP-enabled TP-Link switches is running firmware with a build date earlier than June 2022, the number of all STP-enabled switches should not exceed 20, otherwise loops will occur.
3. If all STP-enabled TP-Link switches are running firmware with a build date later than June 2022, the total number should not exceed 40.
4. MSTP is supported in standalone mode, but not supported in Omada SDN Controller mode.
I. Configuration Overview
To use STP in Omada SDN Controller mode, first, you need to enable STP globally for each switch, then for the ports participating in STP.
1. Enable STP globally.
Click the switches one by one on the Devices page, and go to Config > Services.
Check RSTP and define the Priority if necessary, then click Apply.
Or you can click Batch Action > Batch Config, choose all switches, then click Done.
Go to Config > Services, choose “RSTP”, and click Apply. Then configure the Priority one by one for those necessary.
Priority is a parameter used to determine the root bridge. The priority range is 0 to 61440 in increments of 4096, and the default is 32768. The lower the number the more likely the switch will be chosen as the root switch, whose ports will be active under normal operation. You should determine the Priority of each switch based on the network topology, for example, core switches have lower priority values.
2. Enable STP for each port: There are two methods to enable STP for switch ports.
Method 1. Go to Ports, choose the ports that are supposed to participate in STP, click “Edit Selected”, choose “Profile Overrides”, set Loopback Control to Spanning Tree, and leave the others as Keep Existing.
Method 2. Go to Settings > Wired Networks > LAN > Profile, you can create a new profile, select the Networks/VLANs according to your network settings, and set Loopback Control to Spanning Tree.
Then go back to choose the ports, click “Edit Selected” and change the Profile to the one you just created.
II. Check Operation Status
In TP-Link switches, the port status includes Blocking, Learning, Forwarding, and Disconnected, as explained below.
- Blocking: is the state of the ports blocked. The port receives and sends BPDUs, while the other packets are dropped.
- Learning: The port receives and sends BPDUs, while also receives the other user packets to update its MAC address table, but doesn’t forward them. This is a transitional state.
- Forwarding: is the state of the ports in normal operation. The port receives and sends BPDUs, and also receives the other user packets to update its MAC address table, and forwards them,
- Disconnected: The port is enabled with STP, but not connected to any device.
There are two places on the controller page where you can view the switch port states.
First, on the Devices page, click the switch, and you can see that the blocked ports will be displayed with “STP Blocking”.
You can also check the states through Insight > Switch Status, selected “Connected”, then the STP states of all active ports will be listed.
III. Configuration Examples
In the network as shown below, to achieve high performance and high reliability, we use two TL-SX3016F as the core switches, multiple TL-SG3428X and TL-SG3428XMP as the access switches. We will configure RSTP so that Core Sw 1 is the primary core switch, Core Sw 2 is the backup. When the link between the access switch and Core Sw 1 fails, or when Core Sw 1 fails, Core Sw 2 will quickly take over to reduce the impact.
1. Connect and adopt the switches
Network loops must be avoided before the configuration is complete. Connect the switches with necessary links, as shown in the figure below.
Make sure your Omada SDN Controller has discovered all the switches and successfully adopted them.
2. Configure LAG (optional).
We will use the LAG to connect two core switches. Click Core Sw 1 on the Devices page, go to Ports, select a port for connecting Core Sw 2, check “Profile Overrides”, change the operation mode to Aggregating, choose the other ports for connecting Core Sw 2, set the LAG ID as 1, choose Static LAG or LACP according to your network requirements, click “Apply” to make the settings take effect.
Do similar settings on Core Sw 2. Note that the LAG ID should be the same on both switches.
Then connect both Core switches with multiple links and check that the network is operating properly.
3. Configure STP.
We want Core Sw 1 to be the primary switch, and Core Sw 2 to be the backup, therefore, in normal operation status, the backup links and blocked ports should be as shown below. To achieve such a network topology, we should configure the highest priority for Core Sw 1, the middle priority for Core Sw 2, and low priorities for the access switches.
Enable STP on all switches according to the configuration method above. Configure priority 4096 for Core Sw 1, priority 8192 for Core Sw 2, and keep the default priority 32768 for the other switches.
Enable STP on the desired ports, and don’t forget to enable STP for LAG as well (Ports > LAG, Edit LAG1, Profile Overrides, or modify Profile).
4. Connect other links.
Make sure STP is enabled on all desired links, then connect the links and monitor the operation status of the switches.
Был ли этот FAQ полезен?
Ваш отзыв поможет нам улучшить работу сайта.
![Community](https://static.tp-link.com/assets/images/icon/community.png)
Сообщество TP-Link
Нужна помощь? Задавайте вопросы, находите ответы и обращайтесь за помощью к специалистам TP-Link и другим пользователям со всего мира.