Layer2 Discovery Protocols ============================== .. toctree:: :maxdepth: 1 :hidden: :includehidden: STP RSTP MSTP SPB TRILL This section introduces essential protocols for Layer2 discovering and organizing networked devices. These protocols play a critical role in topology awareness, automation, and network resiliency. .. list-table:: :widths: 15 65 20 :header-rows: 1 * - Protocol - Description - Use Case * - STP (Spanning Tree Protocol) - Prevents Layer 2 loops by detecting redundant links and blocking them. *Ensures a loop-free topology.* - Loop prevention in Ethernet networks. * - RSTP (Rapid Spanning Tree Protocol) - Enhanced STP (IEEE 802.1w) offering much faster convergence and backward compatibility. *Rapid reconfiguration in dynamic networks.* - Fast failover and recovery in Ethernet networks. * - MSTP (Multiple Spanning Tree Protocol) - Extends RSTP to support multiple spanning trees per VLAN instance (IEEE 802.1s). *Scalable spanning tree for VLAN-based segmentation.* - VLAN-aware efficient path management, load‑balanced redundant links. * - SPB (Shortest Path Bridging) - Link-state protocol (IEEE 802.1aq) allowing all paths active with equal cost multipathing. *Efficient Ethernet mesh routing.* - High-performance Ethernet fabrics, faster convergence, multipath traffic distribution. * - TRILL (Transparent Interconnection of Lots of Links) - Routing bridges using IS-IS link-state for Ethernet, combining routing and bridging. *Loop-free, resilient, and efficient path routing in Ethernet networks.* - Fabric-level Ethernet deployment with optimal path routing and resiliency. .. tab-set:: .. tab-item:: STP **RFC:** IEEE 802.1D **Main Features:** - Prevents Layer 2 Ethernet loops by blocking redundant paths - Elects root bridge and calculates shortest path trees - Supports RSTP and MSTP variants for faster convergence and scalability **Use Cases:** - Loop prevention in Ethernet networks - Managing redundant switch links - Avoiding broadcast storms and network downtime **Alternative Protocols:** - RSTP (802.1w) – Rapid Spanning Tree Protocol - MSTP (802.1s) – Multiple Spanning Tree Protocol .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: What You Will Learn in This Section **Let us learn more about STP:** * :ref:`Learnings in this section ` * :ref:`Terminology ` * :ref:`Version Info ` * :ref:`STP Version&IEEE Details ` * :ref:`STP Basic Setup on Ubuntu ` * :ref:`STP Protocol Packet Details ` * :ref:`STP Usecases ` * :ref:`STP Basic Features ` * :ref:`STP Feature : Loop Prevention ` * :ref:`STP Feature : Redundancy Support ` * :ref:`STP Feature : Automatic Topology Change Handling ` * :ref:`STP Feature : Bridge Election ` * :ref:`STP Feature : Port Roles Assignment ` * :ref:`STP Feature : Path Cost Calculation ` * :ref:`STP Feature : Timer Based Operation ` * :ref:`STP Feature : Dynamic Reconfiguration ` * :ref:`STP Feature : Standardized Protocol ` * :ref:`STP Feature : Layer 2 Operation ` * :ref:`Reference links ` .. button-link:: ./STP.html :color: primary :shadow: :expand: Jump to "STP" .. tab-set:: .. tab-item:: RSTP (Rapid Spanning Tree Protocol) **RFC / Standard:** IEEE 802.1w (incorporated into IEEE 802.1D‑2004) **Main Features:** - Enhanced version of STP offering much faster convergence—typically within milliseconds or a few seconds :contentReference[oaicite:0]{index=0} - Simplified port states: discarding, learning, forwarding (merging STP’s blocking, listening, disabled into “discarding”) :contentReference[oaicite:1]{index=1} - Introduces new port roles: alternate and backup, in addition to root and designated :contentReference[oaicite:2]{index=2} - Built-in BPDU handshake and rapid transition mechanisms, faster failure detection (e.g. via frequent Hello messages and keep-alive BPDUs) :contentReference[oaicite:3]{index=3} **Use Cases:** - Rapid failover and recovery in Ethernet networks - Retaining loop protection while massively reducing downtime **Alternative Protocols:** - STP – slower convergence - MSTP – multiple-instance spanning trees for VLAN environments .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: What You Will Learn in This Section **Let us learn more about RSTP:** * :ref:`Learnings in this section ` * :ref:`Terminology ` * :ref:`Version Info ` * :ref:`RSTP Version&IEEE Details ` * :ref:`RSTP Basic Setup on Ubuntu using IPv4 ` * :ref:`RSTP Basic Setup on Ubuntu using IPv6 ` * :ref:`RSTP Protocol Packet Details ` * :ref:`RSTP Usecases ` * :ref:`RSTP Basic Features ` * :ref:`Reference links ` .. button-link:: ./RSTP.html :color: primary :shadow: :expand: Jump to "RSTP" .. tab-set:: .. tab-item:: MSTP (Multiple Spanning Tree Protocol) **RFC / Standard:** IEEE 802.1s (integrated into IEEE 802.1Q with STP/RSTP) **Main Features:** - Supports multiple spanning tree instances (MSTIs), each serving a group of VLANs :contentReference[oaicite:4]{index=4} - Reduces number of spanning trees while allowing VLAN-based path segmentation - Preserves RSTP characteristics—fast convergence and compatibility with STP devices **Use Cases:** - Scalable VLAN deployment in large Ethernet networks - Load balancing traffic by mapping VLANs to separate spanning tree instances **Alternative Protocols:** - RSTP – single spanning tree for all VLANs - STP – legacy slow convergence .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: What You Will Learn in This Section **Let us learn more about MSTP:** * :ref:`Learnings in this section ` * :ref:`Terminology ` * :ref:`Version Info ` * :ref:`MSTP Version&IEEE Details ` * :ref:`MSTP Basic Setup on Ubuntu using IPv4 ` * :ref:`MSTP Basic Setup on Ubuntu using IPv6 ` * :ref:`MSTP Protocol Packet Details ` * :ref:`MSTP Usecases ` * :ref:`MSTP Basic Features ` * :ref:`Reference links ` .. button-link:: ./MSTP.html :color: primary :shadow: :expand: Jump to "MSTP" .. tab-set:: .. tab-item:: SPB (Shortest Path Bridging) **RFC / Standard:** IEEE 802.1aq (part of IEEE 802.1Q) **Main Features:** - Uses a link-state control plane (IS-IS) to learn full topology and compute shortest paths :contentReference[oaicite:5]{index=5} - Allows all links to be active simultaneously with equal-cost multipath forwarding - Supports VLAN segmentation (SPBV) and encapsulated Ethernet (SPBM) for scalable domains **Use Cases:** - High-scale Ethernet fabrics with efficient load-sharing and resiliency - Data center and campus mesh networks needing rapid convergence **Alternative Protocols:** - STP/RSTP/MSTP – loop-free but blocking redundant paths - TRILL – alternative routing bridging approach .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: What You Will Learn in This Section **Let us learn more about SPB:** * :ref:`Learnings in this section ` * :ref:`Terminology ` * :ref:`Version Info ` * :ref:`SPB Version&IEEE Details ` * :ref:`SPB Basic Setup on Ubuntu using IPv4 ` * :ref:`SPB Basic Setup on Ubuntu using IPv6 ` * :ref:`SPB Protocol Packet Details ` * :ref:`SPB Usecases ` * :ref:`SPB Basic Features ` * :ref:`Reference links ` .. button-link:: ./SPB.html :color: primary :shadow: :expand: Jump to "SPB" .. tab-set:: .. tab-item:: TRILL (Transparent Interconnection of Lots of Links) **RFC / Standard:** IETF TRILL protocol (not an IEEE spec, developed by IETF) **Main Features:** - Combines bridging and link-state routing using IS-IS for Ethernet forwarding decisions :contentReference[oaicite:6]{index=6} - RBridges encapsulate frames, support load distribution, multicast, and resilience - Avoids loops without relying on spanning trees, yet interoperates with traditional bridges **Use Cases:** - Fabric-layer Ethernet deployments needing optimal routing and high availability - Resilient data center meshes with efficient broadcast/multicast handling **Alternative Protocols:** - SPB – IEEE-approved link-state fabric - STP/RSTP/MSTP – stricter loop avoidance, less efficient path use .. panels:: :container: container pb-4 :column: col-lg-12 p-2 :card: What You Will Learn in This Section **Let us learn more about TRILL:** * :ref:`Learnings in this section ` * :ref:`Terminology ` * :ref:`Version Info ` * :ref:`TRILL Version&IEEE Details ` * :ref:`TRILL Basic Setup on Ubuntu using IPv4 ` * :ref:`TRILL Basic Setup on Ubuntu using IPv6 ` * :ref:`TRILL Protocol Packet Details ` * :ref:`TRILL Usecases ` * :ref:`TRILL Basic Features ` * :ref:`Reference links ` .. button-link:: ./TRILL.html :color: primary :shadow: :expand: Jump to "TRILL"