Spanning Tree Extention
Spanning Tree Extension
Cisco has provided some STP extension feature to prevent loop in Layer-2 Domain, Error or loop occurred due to user mis configuration. These extension are spanning tree edge ports which is functionality previously known as PortFast, Bridge Assurance, BPDU Guard, BPDU Filtering, Loop Guard, Root Guard.
We will first understand all spanning tree port types and then we will discuss all other features.
STP Port Types:
A port can be configured as three ways in STP, it can be edge port m Normal port, and Network Port.
STP Edge Port: Edge port are those port where host are connected, It worked same as panning-tree port fast, as it transit to forwarding state bypassing listening and learning state. We should not connect switches on port configured as edge port.
STP network Port: These are the ports used to connect the switch as access or trunk ports. These ports can receive and send the BPDU and participate in STP calculation.
STP Normal Port: Any port who are not part of any above port type discussed falls under normal port. When any port have no configuration on it, by default it is the STP normal ports.
Below example shows how to configure all access ports connected to Layer 2 hosts or all ports connected to Layer 2 switches or bridges as spanning tree edge ports:
Below example shows how to configure a particular port in these STP port types.
- Spanning-tree port type edge—enables edge behavior on the access port.
- Spanning-tree port type edge trunk—enables edge behavior on the trunk port.
Bridge Assurance is feature which is used to detect and prevent the loop after detecting unidirectional link behavior due to Software failure or control plane issue and not due to physical layer.
Bridge Assurance not only prevent the loop but it continues to send the data traffic. Bridge Assurance is enabled by default on spanning tree port type network that are point to point link. To enable Bridge Assurance, it must be enabled on both end, it only one side is enabled with BA and another side is not enabled or dies not support, and the connecting ort will be blocked.
When BA is enabled, for each hello timer, BPDU will be sent and received on all operation port along with alternate and backup ports. When any port does not receive the BPDU on any connecting ports for specified period, the port moves to blocked state and as soon as port start receiving BPDU it resumes it normal STP state and start participating in STP calculation.
Let’s understand this with below figure