Menu
Spanning Tree Protocol (STP) Operation by Anthony Sequeira

STP prevents Layer 2 loops - which might result in a broadcast storm or corruption of a switch's MAC address table - from occurring in a network. Switches in an STP topology are classified as one of the following:

• Root bridge: A root bridge is a switch elected to act as a reference point for a spanning tree. The switch with the lowest bridge ID (BID) is elected as the root bridge. The BID is made of of a priority value and a MAC address.

• Nonroot bridge: All other switches in the STP topology are nonroot bridges.

Figure 11-15 illustrates root bridge election in a network. Notice that in this case, the bridge priorities are both 32768, the switch with the lowest MAC address (that is, SW1) is elected as the root bridge.

Ports that interconnect switches in an STP topology are categorized as one of the port types described in Table 11-3.

Port TypeDescription
Root port Every nonroot bridge has a single root port, which is the port on that switch that is closest to the root bridge in terms of cost.
Designated port Every network segment has a single designated port, which is the port on that segment that is the closest to the root bridge in terms of cost. Therefore, all ports on a root bridge are designated ports.
Nondesignated port Non-designated ports block traffic to create a loop-free topology.

Figure 11-16 illustrates these port types. Notice that both links are equal in this case, with a cost of 19, because it has the lowest port ID.

Figure 11-17 shows a similar topology to Figure 11-16. In Figure 11-17, however, the top link is running at a speed of 10Mbps, whereas the bottom link is running at a speed of 100Mbsp. Because switch SW2 seeks to get back to the root bridge (that is, switch SW1) with the least cost,, port Gig 0/2 on switch SW2 is selected as the root port.

Specifcally, port Gig 0/1 has a cost of 100, and Gig 0/2 has a cost of 19. Table 11-4 shows theh port costs for various link speeds.

Link SpeedSTP Port Cost

10Mbps100
100Mbps19
1Gbps4
10Gbps2

Nondesignated ports do not forward traffic during normal operation but do receive bridge potocol data units (BPDUs). Switches exchange STP information in the form of BPDUs, which contain useful information for STP elections, path cost calculation, link suppression, and loop detection. If a link in the topology goes down, the nondesignated port detects the link failure and determines whether it needs to transition to the forwarding state.

If a nondesignated port needs to transition to the forwarding state, it does not do so immediately. Rather, it transitions through the following states:

• Blocking: The port remains in the blocking state for 20 seconds by default. During this time, the nondesignated port evaluates BPDUs is an attempt to determine its role in the spanning tree.

• Listening: The port moves from the blocking state to the listening state and remains in this state for 15 seconds by default. During this time, the port sources BPDUs, which inform adjacent switches of the port's intent to forward data.

• Learning: The port moves from the listening state to the learning state and remains in this state for 15 seconds by default. During this time, the port begins to add entries to its MAC address table.

• Forwarding: The port moves from the learning state to the forwarding state and begins to forward frames.

About The Author

Anthony Sequeira, CCIE No. 15626, is a Cisco Certified Systems Instructor (CCSI) and author regarding all levels and tracks of Cisco Certification. Anthony formally began his career in the information technology industry in 1994 with IBM in Tampa, Florida. He quickly formed his own computer consultancy, Computer Solutions, and then discovered his true passion-teaching and writing about Microsoft and Cisco technologies. Anthony joined Mastering Computers in 1996 and lectured to massive audiences around the world about the latest in computer technologies. Mastering Computers became the revolutionary online training company, KnowledgeNet, and Anthony trained there for many years. Anthony is currently pursuing his second CCIE in the area of Security and is a full-time instructor for the next-generation of KnowledgeNet, StormWind.com. Anthony is also a VMware Certified Professional.

CompTIA Network+ N10-008 Cert Guide contains proven study features that allow you to succeed on the exam the first time. Expert instructor Anthony Sequeira shares preparation hints and test-taking tips, helping you identify areas of weakness and improve both your conceptual knowledge and hands-on skills, essential for successful completion of the performance-based testing items on the exam. This complete, CompTIA-approved study package includes the following:

A test-preparation routine proven to help you pass the exams
Clearly defined chapter learning objectives covering all N10-008 exam topics
Chapter-ending review questions and exam preparation exercises, which help you drill on key concepts you must know thoroughly
The powerful Pearson Test Prep practice test software, complete with hundreds of well-reviewed, exam-realistic questions, customization options, and detailed performance reports
40 performance-based exercises to help you prepare for the hands-on exam questions
A free copy of the CompTIA Network+ N10-008 Simulator Lite software, complete with meaningful lab exercises that enhance your hands-on skills
More than 60 minutes of video mentoring
A final preparation chapter that guides you through tools and resources to help you craft your review and test taking strategies
An Exam Essentials appendix that quickly recaps all major chapter topics for easy reference, both in print and interactive digital format
A key terms Glossary in both print and on the companion website, which acts as an interactive flash-card application
Study plan suggestions and templates to help you organize and optimize your study time
A 10% exam discount voucher (a $33+ value!)

Well regarded for its level of detail, study plans, assessment features, challenging review questions and exercises, video instruction, and hands-on labs, this approved study guide helps you master the concepts and techniques that ensure your exam success.

Master the topics on the CompTIA Network+ N10-008 exam, including:

Network topologies and media types
IP addressing
Network services
Data center architectures and cloud concepts
Routing, Ethernet switching, and wireless networking
Network availability and disaster recovery
Network security
Remote access
Network troubleshooting

Reader Paulo Cardoso says, "This is a great book. In addition, it comes with great additional resources."

Learn more about the CompTIA Network+ N10-008 Cert Guide at amazon.com


Learn more at amazon.com

More Networking Topologies Articles:
• Frame Relay WAN Protocol
• Six Things You Must Know About Fiber Optic Cable Materials
• Wireless Network Vlans - How to Implement Wireless Vlans
• Understanding Basic Terms in Indoor Fiber Optic Cable Installation
• Access Points and Wireless LAN Controller
• Fiber Media Converter - What's the Use and How to Choose It
• Computer Network Routers, Hubs, and Switches
• What is an Ethernet Switch?
• What is an Ethernet Bridge?
• MPO Connector, MTP Connector, What's the Difference?