Spanning treeIntermediate23 min read

What Does Blocking state Mean?

Reviewed byJohnson Ajibi· Senior Network & Security Engineer · MSc IT Security
On This Page

Quick Definition

In a network with multiple paths, the blocking state temporarily stops a port from sending or receiving data. This prevents network loops that could cause data to circulate endlessly. Only one path is allowed to forward traffic at a time, and all other redundant paths are placed in blocking state.

Commonly Confused With

Blocking statevsListening state

Both blocking and listening are non-forwarding states, but listening is a transitional state where the port starts sending and receiving BPDUs to determine its role. In blocking, the port only receives BPDUs and does not send them. Listening occurs after blocking and before learning in classic STP.

A port is in blocking when the network first boots up. After 15 seconds, it moves to listening, where it actively participates in STP election. If it becomes a designated port, it then moves to learning.

Blocking statevsLearning state

In learning state, the port still does not forward data frames, but it begins to learn MAC addresses from incoming frames, building the MAC address table. Blocking state does no MAC learning. Learning happens after listening and before forwarding.

When you plug a new switch into the network, its port goes through blocking (20 sec default), then listening (15 sec), then learning (15 sec). In learning, it starts populating its MAC table, but still no data is forwarded.

Blocking statevsError-disabled state

Error-disabled is a port state where the switch has administratively shut down the port due to a security violation (like BPDU guard, port security, or loop guard). This is a failure state requiring manual recovery or errdisable recovery configuration. Blocking state is a normal STP state and does not indicate a fault.

If you enable BPDU guard on an access port and a rogue switch sends a BPDU, the port goes to errdisable. The port LED is off, and no traffic passes. In blocking state, the port LED is still on (often orange), and BPDUs are still received.

Must Know for Exams

For the CCNA exam (200-301), blocking state is a core topic under the 'Spanning Tree Protocol' domain. Cisco emphasizes understanding STP operations, port states, and the purpose of each state. You may be asked to identify which state a port is in based on a scenario, or to explain why a port is in blocking state. The exam objectives explicitly state that candidates must be able to 'describe STP operation' and 'explain STP port states and transitions'.

Questions often present a simple topology of two or three switches and ask you to determine which ports are in blocking state after STP convergence. You need to know that the root bridge ports are all forwarding, designated ports are forwarding, and only non-designated ports are blocking. You might also be asked about the timer values: Blocking state lasts until the Forward Delay timer expires (15 seconds), and then the port moves to Listening (15 seconds) and then Learning (15 seconds) before forwarding. However, in RSTP, the blocking state is replaced by discarding, and convergence is faster.

Another common exam topic is the difference between STP port states. You may get a multiple-choice question like: 'In which STP port state does a switch learn MAC addresses but does not forward data frames?' The answer is Learning state. Or 'In which state does a switch only receive BPDUs?' Answer: Blocking. You must remember that Blocking only receives BPDUs, Listening receives and sends BPDUs but does not learn MACs, Learning receives and sends BPDUs and learns MACs but does not forward, and Forwarding does everything.

The CCNA exam also tests your understanding of PortFast, which allows a port to skip blocking and listening and go directly to forwarding. But you must know that PortFast is only safe on access ports (end devices), not on trunk ports between switches. If you use PortFast on a switch-to-switch link, you might create a loop before STP converges.

Finally, expect troubleshooting scenarios. For example, 'A user reports they cannot access the network. You check the switch and see the port is in blocking state. What is the most likely cause?' The answer might be that the port is part of a redundant link and STP correctly placed it in blocking state (normal operation) or that there is a BPDU guard issue. Understanding these distinctions is critical for passing the CCNA.

For other exams like CompTIA Network+, blocking state appears as a basic concept, but the depth is lower. The CCNA is the primary exam where blocking state is tested in detail.

Simple Meaning

Imagine a busy intersection in a city where traffic lights are not working. Without control, cars would crash and block each other. Now imagine a traffic officer who decides that only one road at a time can have the green light. All other roads get a red light, meaning stop and wait. That red light is like the blocking state in a computer network. When you have switches connected in a way that creates multiple paths (like a loop), the network uses Spanning Tree Protocol (STP) to avoid chaos. STP elects one path as the best (the green light) and puts all other paths into blocking state (the red light). In this state, the switch port does not send or receive normal data traffic. It only listens for special messages called Bridge Protocol Data Units (BPDUs) that tell it if the main path has failed. If that fails, the blocking port can change to a forwarding state to keep the network running. Without blocking state, data frames would travel in an endless loop, causing the network to slow down or crash completely. So blocking state is a safety mechanism that keeps the network stable and efficient by preventing loops while still keeping backup paths ready.

In everyday terms, think of a conference room with two doors. If everyone tries to enter through both doors at the same time, people get stuck and nothing moves. So you block one door completely and only use the other. If the open door gets jammed, you then unblock the second door so people can still enter. That's exactly what blocking state does for network traffic.

For learners new to networking, the key point is that blocking state is not a failure. It is a deliberate, controlled state that ensures the network remains loop-free. Switches in blocking state are still active, listening for changes, and ready to take over if needed. This makes the network both reliable and efficient.

Full Technical Definition

Blocking state is one of the five port states defined by the IEEE 802.1D Spanning Tree Protocol standard. It is a temporary state that prevents a switch port from forwarding data frames, learning MAC addresses, or sending its own BPDUs. The only operation a port in blocking state performs is receiving BPDUs from other switches. This ensures that no Layer 2 loops form in a redundant topology.

When STP converges, the protocol elects a root bridge and determines which ports are designated (forwarding) and which are non-designated (blocking). A port in blocking state has been identified as providing a redundant path that would create a loop if allowed to forward traffic. The port remains in this state until the network topology changes, for example, when a link failure occurs on the forwarding path.

During the STP convergence process, a port passes through several states: blocking, listening, learning, and finally forwarding (or back to blocking). In the blocking state, the port discards all incoming and outgoing data frames. It does not learn MAC addresses from incoming frames. It only processes received BPDUs to monitor the network topology. The port does not send its own BPDUs, which helps maintain the STP hierarchy decided by the root bridge.

A port typically stays in blocking state for about 20 seconds (the Forward Delay timer) before transitioning to listening state if the root bridge decides the port is now the best path. However, with Rapid Spanning Tree Protocol (RSTP, IEEE 802.1w), the blocking state is replaced by discarding state, and convergence happens much faster, often within a few seconds.

In real IT implementations, blocking state is critical for redundant network design. Network engineers deliberately create multiple links between switches to provide failover protection, and rely on STP to place redundant links in blocking state. This provides a loop-free topology while maintaining backup paths. For example, in a data center, three switches might be interconnected. STP will place two of the six possible connections in blocking state to prevent loops, leaving four forwarding paths that provide both redundancy and load balancing capabilities. Without blocking state, broadcast storms, multiple frame copies, and MAC table instability would bring down the network.

Cisco's implementation of STP follows the 802.1D standard but also includes enhancements such as PortFast, UplinkFast, and BackboneFast. PortFast allows ports connected to end devices (like PCs) to skip the blocking and listening states and move directly to forwarding, which speeds up boot time. However, PortFast should never be used on ports that connect to other switches, as it would bypass the loop prevention mechanism of blocking state.

blocking state is a fundamental part of STP that makes Layer 2 redundancy possible without causing network loops. It is an active, non-forwarding state that provides loop protection and fast failover capability.

Real-Life Example

Think about a large highway system with multiple routes between two cities. To prevent congestion and accidents, traffic controllers set up a system where only one main highway is open for travel at any given time. All other highways between the same cities are blocked with barriers and warning signs. However, those barriers are not permanent. They can be removed quickly if the main highway becomes blocked or needs repairs. The closed highways are kept in good condition, just waiting to be used.

Now imagine your home internet. You have one main path from your router to your computer. If that cable fails, your internet stops. But what if you had a second cable? The network would need to decide which cable to use, or else data might get confused trying both. The blocking state is like the barrier on the second highway. It keeps the extra cable ready but unused.

In a company network, imagine three office buildings connected by fiber optic cables. Building A connects to Building B, Building B connects to Building C, and Building C also connects directly back to Building A. This creates a triangle. If all three paths were active, data could circulate forever around the triangle. So STP blocks one of those connections. Let's say it blocks the direct link between Building C and Building A. Now data flows from A to B to C, but the blocked link is still there, ready to be used if the link between B and C fails. When that happens, the blocked port becomes forwarding, and traffic flows again through the backup path.

This analogy shows that blocking state is not a problem. It is a planned, intelligent feature that allows networks to have redundancy without chaos. Just as highway barriers can be removed when needed, blocking ports can switch to forwarding in seconds, keeping the network running smoothly.

Why This Term Matters

In real-world networking, downtime is expensive. Companies lose money every minute their network is down. One of the most common causes of network outages is accidental loops. A loop can happen when a technician plugs a cable into the wrong port, when a new switch is added without proper planning, or when a redundant link activates incorrectly. Without STP and blocking state, that loop would cause a broadcast storm that saturates all bandwidth, making the network completely unusable. Users would be unable to access email, files, or the internet. Hours of productivity could be lost.

Blocking state prevents this. It is the core loop prevention mechanism in Ethernet networks. Even when network engineers intentionally create redundant links for failover, blocking state ensures that only one path is active at a time. This provides high availability without the risk of loops. In modern data centers, where uptime is measured in nines (99.999%), blocking state is a critical component of the network design.

blocking state is essential for network stability. Without it, switches would constantly learn and forget MAC addresses as frames arrived from multiple paths, causing MAC table flapping. This would degrade switch performance and could even crash the switch. Blocking state stops this by ensuring that only the forwarding path learns MAC addresses, keeping the MAC table consistent.

For IT professionals, understanding blocking state is necessary for troubleshooting network issues. If a user cannot reach a server, and you discover a port is in blocking state, you need to determine if that is normal (backup path) or abnormal (incorrect STP configuration). Network engineers also need to tune STP timers and use features like PortFast and BPDU guard to optimize convergence time and enhance security. Without a solid grasp of blocking state, you cannot design, configure, or troubleshoot a switched network effectively.

blocking state matters because it enables reliable, redundant, and loop-free networks. It is a foundational concept for any network professional working with Ethernet switches.

How It Appears in Exam Questions

Multiple-choice questions often ask about the characteristics of blocking state. For example: 'Which of the following is true about a switch port in blocking state?' The correct answer is that the port receives BPDUs but does not forward data frames or learn MAC addresses. Distractors might include 'forwards data frames' or 'learns MAC addresses'.

Scenario-based questions give a network diagram with three switches connected in a triangle. The question might ask: 'After STP converges, which port on Switch2 will be in blocking state?' You need to know the root bridge election rules (lowest bridge ID) and how designated/non-designated ports are chosen. Typically, the port that is furthest from the root bridge on a redundant link ends up blocking.

Configuration questions might show a switch configuration snippet and ask: 'What is the effect of the command spanning-tree portfast on interface GigabitEthernet0/1?' The answer is that the port will skip blocking and listening states and immediately transition to forwarding, but this should only be used on access ports.

Troubleshooting questions are common. For instance: 'A network administrator notices that a port is stuck in blocking state and never transitions to forwarding. What could be the issue?' Possible causes include: a loop detected, BPDU guard enabled, or the port is configured as a root guard. The answer might be that the port is non-designated and should remain blocking, but if it should be forwarding, check for misconfiguration.

Another type: 'A new switch is connected to the network, and immediately a broadcast storm occurs. What STP feature could have prevented this?' The answer is BPDU guard, which shuts down a port if it receives a BPDU, preventing loops without relying on blocking state.

For CCNA, you may also see drag-and-drop questions where you must order the STP port states correctly: Blocking, Listening, Learning, Forwarding.

Overall, the exam expects you to know what blocking state does, when it is used, how long it lasts, and how to identify it in a topology. Practice with simple topologies until you can quickly determine which ports will block.

Practise Blocking state Questions

Test your understanding with exam-style practice questions.

Practise

Example Scenario

Imagine a small office with three Cisco switches: SwitchA, SwitchB, and SwitchC. SwitchA is connected to SwitchB via port Gi0/1 on both. SwitchB is connected to SwitchC via Gi0/2 on both. SwitchC is also connected directly back to SwitchA via Gi0/3 on both. This creates a triangular loop. The network administrator enables STP (which is on by default on Cisco switches).

First, STP elects a root bridge. Suppose SwitchA has the lowest priority (32768) and lowest MAC address, so it becomes the root bridge. All ports on the root bridge are designated (forwarding). So SwitchA's Gi0/1 (to SwitchB) and Gi0/3 (to SwitchC) are both forwarding.

Now, each non-root switch chooses one root port (the port with the best path to the root). SwitchB sees two paths: directly to SwitchA via Gi0/1 (cost 4), and via SwitchC then SwitchA (cost 4+4=8). The direct path is best, so Gi0/1 on SwitchB becomes the root port (forwarding). The other port on SwitchB (Gi0/2 to SwitchC) is a designated port because the lower-cost path from that segment goes through SwitchB, so it is also forwarding.

SwitchC has two paths: directly to SwitchA via Gi0/3 (cost 4), and via SwitchB (cost 4+4=8). The direct path is best, so Gi0/3 on SwitchC becomes the root port (forwarding). The other port (Gi0/2 to SwitchB) sees that the segment already has a designated port from SwitchB, so SwitchC's Gi0/2 becomes a non-designated port and is placed in blocking state.

Now, traffic flows from any device connected to SwitchC to the root via Gi0/3. The link between SwitchC and SwitchB is blocked. If the link between SwitchC and SwitchA fails, SwitchC's Gi0/3 goes down. After STP recalculates, SwitchC's Gi0/2 will transition from blocking to listening, then learning, then forwarding. At that point, traffic flows through SwitchB to reach the root. The network recovers without any manual intervention.

This scenario shows how blocking state provides a ready backup path that is safe and automatic.

Common Mistakes

Thinking blocking state means the port is broken or misconfigured.

Blocking state is a normal STP operation. It is a deliberate, safe state that prevents loops. A port in blocking state is not faulty; it is doing exactly what it should be doing.

When you see a port in blocking state, first check whether it is intended. In a redundant topology, one or more block ports are expected. Only investigate if the port should be forwarding based on network design.

Believing that a port in blocking state does nothing at all.

Even in blocking state, the port is active. It receives and processes BPDUs from other switches. This allows the switch to detect topology changes and react quickly when needed.

Remember that blocking state is not idle. The port is listening for STP messages and is ready to transition to forwarding if the topology changes.

Assuming that blocking state lasts forever until manually changed.

Blocking state is temporary. After STP convergence, if the port is non-designated, it remains blocking. But if the forwarding path fails, STP will automatically transition the blocking port through listening and learning to forwarding within about 30 seconds (with classic STP).

Know that STP is dynamic. Blocking ports can become forwarding ports automatically when needed. Study the STP timers (Forward Delay, Max Age) to understand the timeline.

Confusing blocking state with error-disable state.

Error-disable state is a failure state caused by events like a BPDU guard violation, loop guard, or other security features. The port is administratively shut down. Blocking state is a normal STP state that does not require manual intervention.

If a port is in errdisable state, the switchport shows status 'err-disabled'. Blocking state is shown as 'blocking' in STP output. Use 'show spanning-tree' to see the difference.

Exam Trap — Don't Get Fooled

{"trap":"During an STP topology change, a port moves from blocking directly to forwarding without going through listening and learning.","why_learners_choose_it":"Learners often think that STP immediately moves to forwarding to restore connectivity quickly. They may also confuse RSTP's faster convergence with classic STP, thinking that RSTP eliminates the listening/learning states."

,"how_to_avoid_it":"In classic 802.1D STP, a port always progresses through blocking -> listening -> learning -> forwarding. Each state lasts 15 seconds (the Forward Delay). RSTP does not have a blocking state; it has discarding, learning, and forwarding.

In RSTP, a port can go from discarding directly to learning and then to forwarding. But never from blocking directly to forwarding in classic STP. On the exam, if the question specifies '802.

1D STP', then the port must go through all four states. If it specifies 'RSTP', then it goes from discarding to learning to forwarding."

Step-by-Step Breakdown

1

Port comes up and initializes

When a switch port is first enabled (cable plugged in, or switch powered on), the port immediately enters blocking state. This is a safety mechanism to prevent any possibility of a loop before STP converges. The port does not forward any data or learn MAC addresses.

2

Port listens for BPDUs (Blocking state)

While in blocking state, the port only receives BPDUs from other switches. It does not send its own BPDUs. By listening to BPDUs, the switch learns about the root bridge, path costs, and port roles. This information is crucial for determining whether this port should eventually become forwarding or remain blocking.

3

Decision: root port or designated port?

After STP converges (max age timer, usually 20 seconds), each non-root switch selects one root port (the best path to the root bridge). All switches then determine which ports are designated (single forwarding port per segment) and which are non-designated. Non-designated ports remain in blocking state. Designated and root ports transition to listening.

4

Transition to listening state (if applicable)

If a port is selected as a root or designated port, it moves from blocking to listening. In listening, the port starts sending its own BPDUs and continues to receive them. It still does not forward data or learn MAC addresses. This state lasts 15 seconds (the Forward Delay timer) and allows time for the port to confirm the topology is stable.

5

Transition to learning state

After 15 seconds in listening, the port moves to learning. In learning, the port still does not forward data frames, but it starts building the MAC address table by learning source MAC addresses of incoming frames. This prevents flooding when the port eventually starts forwarding. This state lasts another 15 seconds.

6

Transition to forwarding state

After 15 seconds in learning, the port moves to forwarding. Now it forwards data frames normally, sends BPDUs, and continues learning MAC addresses. The network is now loop-free and operational with one active path.

7

If topology changes

If the active forwarding path fails (e.g., a link goes down), STP recalculates. The previously blocking port (which remained in blocking throughout) now becomes the best path. It transitions through listening and learning (30 seconds total) to forwarding. This ensures that the backup path takes over seamlessly.

Practical Mini-Lesson

In a production network, you will rarely see ports transitioning through states unless you are troubleshooting or observing during a change. Most of the time, after STP converges, all forwarding ports are in forwarding state, and all redundant ports are in blocking state. As a network professional, you need to know how to verify STP status and interpret the output.

The most important command is 'show spanning-tree' on a Cisco switch. This command shows the root bridge, port roles (Root, Desg, Altn, Back), and port states (FWD, BLK, LRN, LIS). For example, you might see: 'Interface Gi0/1: Role: Desg, State: FWD, Cost: 4' for a forwarding port. For a blocking port: 'Interface Gi0/2: Role: Altn, State: BLK, Cost: 4'. 'Altn' means alternate port, which is a backup to the root port.

If you suspect a loop or STP issue, use 'show spanning-tree vlan <vlan-id>' to check per-VLAN STP. Also use 'show spanning-tree summary' to see if the switch is the root or not. If you need to troubleshoot why a port is blocking when it should be forwarding, check the root bridge status. Perhaps the switch with lower priority is not the intended root, causing unexpected blocking.

Another practical task is configuring STP features. Use 'spanning-tree portfast' on access ports to speed up boot time for end devices. But always combine it with 'spanning-tree bpduguard enable' to protect against accidental loops. For switch-to-switch links, never use PortFast.

You may also need to adjust STP timers, especially in large networks. The Forward Delay timer (default 15 seconds per state) can be tuned, but be careful: setting it too low might cause loops. Cisco recommends using 'spanning-tree vlan <vlan-id> forward-time <seconds>'.

What can go wrong: If you connect a switch with default STP settings and the other switch has a lower bridge priority, the new switch might become root and change the topology, causing unexpected blocking. Always plan your root bridge selection by configuring 'spanning-tree vlan <vlan-id> root primary' on the core switch.

blocking state is a workhorse of STP. In practice, you verify it, trust it, and only intervene when the design is wrong. Knowing how to read 'show spanning-tree' and understanding port roles will serve you well in any network job.

Memory Tip

Blocking = B for BPDU only. The port only listens to BPDUs, no forwarding, no learning.

Covered in These Exams

Current Exam Context

Current exam versions that test this topic — use these objectives when studying.

Related Glossary Terms

Frequently Asked Questions

Does a port in blocking state consume power?

Yes, the port is powered on and active, but it is not forwarding data. It still uses power for the Ethernet interface and for processing received BPDUs.

How long does a port stay in blocking state?

If the port is selected as a non-designated port, it stays in blocking state indefinitely unless the topology changes, causing STP recalculation. If the port is a root or designated port, it transitions to listening after about 20 seconds (Max Age timer).

Can I force a port out of blocking state?

You can use the 'spanning-tree portfast' command on access ports to skip blocking and listening, but this is only for end devices. For switch-to-switch links, you should not force the port out of blocking; it is there for safety.

Is blocking state the same in RSTP?

No. RSTP (802.1w) replaces blocking state with discarding state. Discarding is similar but convergence is faster, and ports can transition directly from discarding to learning.

Why does my port stay in blocking state even though there is only one link?

If you have only one link and the port is blocking, STP might be misconfigured. Perhaps the switch thinks there is a loop due to another connection, or the port is connected to a switch that has a higher priority but no alternate path. Check the spanning-tree topology.

What is the difference between blocking and disabled state?

Disabled state means the port is administratively shut down (shutdown command). No traffic or BPDUs are sent or received. Blocking state is a normal STP state where the port is still receiving BPDUs and ready to transition.

Summary

Blocking state is a critical STP port state that prevents Layer 2 loops in redundant switched networks. When a switch port is in blocking state, it does not forward data frames or learn MAC addresses. It only receives BPDUs, which allows the switch to monitor the network topology and detect changes. This state is normal and intentional, providing a safe loop-free environment while maintaining backup paths for failover.

For network professionals, understanding blocking state is essential for designing reliable networks and troubleshooting connectivity issues. It is a foundational concept for the CCNA exam, where candidates are tested on STP operation, port states, timers, and configuration. Common mistakes include thinking blocking state is a fault, confusing it with errdisable, or misinterpreting STP behavior.

blocking state is not a problem. It is a solution. It allows networks to have redundancy without loops, ensuring high availability and stability. Master this concept, and you will have a strong understanding of how Ethernet switches keep data flowing safely. Whether you are studying for CCNA or working in the field, knowing blocking state will help you design, configure, and troubleshoot modern networks effectively.