• Imagine a small company expanding its local network. To improve reliability, the administrator connects the switches using multiple redundant links. A few minutes later, users start complaining, the network becomes slow, pings time out, and broadcast traffic floods the LAN.

    Layer 2 network loop example with redundant links between switches before enabling STP

    Figure 1 – Example of a Layer 2 loop created

    What happened?

    The network has fallen into a Layer 2 loop, a classic issue that can bring even simple Ethernet topologies to a halt. Frames endlessly circulate between switches because there’s no mechanism to stop them.

    This is exactly the kind of disaster Spanning Tree Protocol (STP) was designed to prevent. STP ensures that even if multiple links exist between switches, only one logical path remains active. The others are placed in a blocking state to avoid loops but can reactivate instantly if a failure occurs.

    In this lab, you’ll learn how to configure the Spanning Tree Protocol and how to control which switch becomes the Root Bridge, the central decision-maker in any STP topology.

    Network Topology Overview

    Now that you understand why STP is necessary, let’s see how to configure it in practice.
    Here is the topology you will use:

    • SW1 as the Root Bridge

    • SW2 as the Backup Root Bridge

    • SW3 with Default priority switch serving as a NON-ROOT switch

    spanning tree protocol configuration topology\n

    Figure 2 – Three-switch topology with Root, Backup, and Non-Root switches.

    The term Backup Root Bridge may be new for you.
    Don’t worry, in this lab, you’ll see exactly what it does and why we use it in an STP topology.

    How to Begin

    Before starting, download the lab file using the button at the top of the page.
    You’ll find a ready-made topology with all necessary VLANs and switch interfaces already configured, so you can focus entirely on the Spanning Tree Protocol setup.

    Lab Overview

    Here’s the structure we’ll follow throughout this lab:

    Step 1 – Identify the current STP election
    Step 2 – Configure SW1 as the Root Bridge
    Step 3 – Configure SW2 as the Backup Root Bridge
    Step 4 – Observe STP blocked link

    Let’s Get Started

    In the next sections, we’ll walk through each configuration step together, explain the commands, and verify that everything works correctly.

    Answer the question below