fbpx

Unraveling BPDUs: How BPDUs Keep the Network Moving

Facebook
Twitter
LinkedIn
WhatsApp
Telegram

Bridge Protocol Data Units (BPDU = Bridge Protocol Data Unit), are data messages used in the Spanning Tree Protocol (STP) to share information about the network topology between all switches in the network.

At the end of the article you will find a small test that will allow you assess the knowledge acquired in this reading

BPDU Types

There are three types of BPDUs: Configuration BPDU (also known as standard BPDU), Topology Change Notification (TCN) BPDU, and Rapid Spanning Tree Protocol (RSTP) BPDU.

1. Configuration BPDU

These are the most common BPDUs, sent regularly (every 2 seconds by default) by all switches in the network to exchange information about the topology. A Configuration BPDU contains the following information:

    • Root Bridge ID: An 8-byte identifier for the switch believed to be the root bridge. The root bridge is the central switch in the STP topology.
    • Sender Bridge ID: An 8-byte identifier for the switch that sent the BPDU.
    • Port ID: A 2-byte identifier for the port that sent the BPDU.
    • Path Cost: The sum of the costs of all links from the switch sending the BPDU to the root bridge.
    • Age, Max Age, Hello Time, Forward Delay: Time variables used to determine the lifetime and propagation of BPDUs.
    • flags: They indicate the state of the network, such as changes in topology.

2. Topology Change Notification (TCN) BPDU

These are sent when a switch detects a change in the network topology, such as when a port changes state (from blocked to forward, or vice versa).

The switch that detects the change sends a TCN BPDU to the root bridge, which then sends a topology change confirmation BPDU to all other switches.

3. Rapid Spanning Tree Protocol (RSTP) BPDU

RSTP BPDU is similar to the Configuration BPDU, but is used in the Rapid Spanning Tree Protocol (RSTP), which is an evolution of the original STP designed to converge more quickly. The RSTP BPDU introduces several new fields and changes the use of some existing fields.

Comparative table of the 3 types of BPDUs

 Configuration BPDUTopology Change Notification (TCN) BPDURapid Spanning Tree Protocol (RSTP) BPDU

Primary use

Exchange network topology information between switches and select the Root Bridge.Notify other switches about a change in network topology.Used in RSTP for faster reconvergence of the network in case of topology changes.

Shipping Frequency

It is sent regularly (every 2 seconds by default) by all switches in the network.It is sent when a switch detects a change in the network topology.It is regularly sent as a Configuration BPDU, but with additional information and changes in the use of some fields to support RSTP.

Information contained

Root Bridge ID, Sender Bridge ID, Port ID, Path Cost, Age, Max Age, Hello Time, Forward Delay, Flags.It does not contain much information, mainly a “change notification” type message.Similar to the Configuration BPDU, but with additional fields to support RSTP, such as Role of the sender, Learning and Forwarding states, etc.

Processing result

The switches use the information to select the Root Bridge, Root Port, and Designated Ports, and block other ports to prevent loops.The switches react to the change in topology, possibly by selecting a new Root Bridge, Root Port, or Designated Ports, and changing the state of some ports.Switches can quickly change network topology in response to changes, allowing for faster reconvergence.

Understanding the comparative table of the three types of BPDUs, it is also essential to highlight the similarities and differences between them:

Similarities

  • All BPDUs are used in the Spanning Tree Protocol (STP) to avoid loops in an Ethernet network and maintain a healthy network.

  • The three types of BPDUs are sent on a network to communicate the network topology and changes to it.

  • All of them are transmitted by switches in a network.

Differences

  • The Configuration BPDU and the RSTP BPDU are sent regularly to share network topology information and switch status, while the TCN BPDU is only sent when there is a change in the network topology.

  • The Configuration BPDU is used in the basic STP, while the RSTP BPDU is used in the Rapid Spanning Tree Protocol, which is a more advanced and faster version of STP.

  • The RSTP BPDU, unlike the Configuration BPDU, contains additional information and changes the use of some fields to support RSTP features, such as the ability to move ports directly into the forwarding state from a non-designated state, without going through the forwarding state. listening and learning, as is done in basic STP.

  • The TCN BPDU is significantly simpler than the other two, as its main purpose is to simply notify other switches about a change in network topology.

Each type of BPDU has a specific purpose and characteristics that make it suitable for its role in managing the Ethernet network topology. The differences between them are mainly in the amount and type of information they contain, the frequency with which they are sent, and how they affect the behavior of switches in the network.

General operation of BPDUs

In a working network, each switch sends BPDUs containing the identification of what it believes is the root bridge.

If a switch receives a BPDU indicating that there is a root bridge with an ID lower than the one it currently has, it will update its information and begin forwarding that BPDU instead of its own.

This process ensures that all switches come to an agreement on which is the root bridge. From there, they use the BPDUs to determine the shortest path to the root bridge, and will block any ports that are not on that path to prevent network loops.

It is important to understand how the Spanning Tree protocol uses these packets to maintain a healthy and functional network.

Choosing the Root Bridge

The process begins with choosing the Root Bridge. Each switch sends a Configuration BPDU with its own Bridge ID as the Root Bridge ID. A Bridge ID is composed of a priority value (2 bytes) and the MAC address of the switch (6 bytes). The switch with the lowest Bridge ID becomes the Root Bridge. In case of a tie in priority, the lowest MAC address decides the Root Bridge.

Choice of Root Ports and Designated Ports

Once the Root Bridge is established, the other switches must determine the best path to it. This is done through Root Ports. Each switch, other than the Root Bridge, will select one of its ports as the Root Port, which is the port with the lowest Path Cost to the Root Bridge.

Designated Ports are those that are on the selected path to reach the Root Bridge. Designated Ports are responsible for sending BPDUs down the network hierarchy so that other switches can find their way to the Root Bridge.

Blocking ports and port roles in RSTP

Ports that are not selected as Root Ports or Designated Ports are blocked to prevent loops. In a blocking state, a port will not send or receive data traffic, but can still receive BPDUs.

RSTP, unlike traditional STP, defines additional roles for ports, such as alternate port and backup port. These roles allow for faster reconvergence of the network if topology changes occur.

Changes in topology and BPDUs

When a change in topology occurs, such as a link going down or coming up, the switches involved begin sending TCN BPDUs toward the Root Bridge. When the Root Bridge receives these BPDUs, it sends a Configuration BPDU to all switches to indicate that there has been a change in the topology and that they should update their information.

Closing remarks

It is important to note that the details above describe the standard behavior of the Spanning Tree protocol and how it uses BPDUs. However, there are several versions and variants of the Spanning Tree protocol (such as RSTP, MSTP, PVST, etc.) that can vary in specific details of how they use BPDUs and other aspects of their operation.

In general, BPDUs are essential to maintain the stability and efficiency of Ethernet networks. They allow communication and coordination between switches to avoid loops, select the best path for traffic, and adapt to changes in network topology.

Brief knowledge quiz

What do you think of this article?
Do you dare to evaluate your learned knowledge?

QUIZ - Unraveling BPDUs: How BPDUs Keep the Network Moving

Do you want to suggest a topic?

Every week we post new content. Do you want us to talk about something specific?
Topic for the next blog

Leave a comment

Your email address will not be published. Required fields are marked with *

DISCOUNT CODE

AN24-LIB

applies to MikroTik books and book packs

Days
Hours
Minutes
Seconds

Introduction to
OSPF - BGP - MPLS

Sign up for this Free course

MAE-RAV-ROS-240118
Days
Hours
Minutes
Seconds

Sign up for this Free course

MAS-ROS-240111

Promo for Three Kings Day!

KINGS24

15%

all the products

MikroTik courses
Academy courses
MikroTik books

Take advantage of the Three Kings Day discount code!

* promotion valid until Sunday January 7, 2024
** the code (KINGS24) applies to shopping cart
*** buy your course now and take it until March 31, 2024

New Year's Eve Promo!

NY24

20%

all the products

MikroTik courses
Academy courses
MikroTik books

Take advantage of the New Year's Eve discount code!

* promotion valid until Monday, January 1, 2024
** the code (NY24) applies to shopping cart
*** buy your course now and take it until March 31, 2024

Christmas discounts!

XMAS23

30%

all the products

MikroTik courses
Academy courses
MikroTik books

Take advantage of the discount code for Christmas!!!

**codes are applied in the shopping cart
Promo valid until Monday December 25, 2023

CYBER WEEK DISCOUNTS

CW23-MK

17%

all MikroTik OnLine courses

CW23-AX

30%

all Academy courses

CW23-LIB

25%

all MikroTik Books and Book Packs

Take advantage of the discount codes for Cyber ​​Week!!!

**codes are applied in the shopping cart
Promo valid until Sunday December 3, 2023

BLACK FRIDAY DISCOUNTS

BF23-MX

22%

all MikroTik OnLine courses

BF23-AX

35%

all Academy courses

BF23-LIB

30%

all MikroTik Books and Book Packs

Take advantage of the discount codes for Black Friday!!!

**Codes are applied in the shopping cart

codes are applied in the shopping cart
valid until Sunday November 26, 2023

Days
Hours
Minutes
Seconds

Sign up for this Free course

MAE-VPN-SET-231115

Halloween promo

Take advantage of discount codes for Halloween.

Codes are applied in the shopping cart

HW23-MK

11% discount on all MikroTik OnLine courses

11%

HW23-AX

30% discount on all Academy courses

30%

HW23-LIB

25% discount on all MikroTik Books and Book Packs

25%

Register and participate in the free course Introduction to Advanced Routing with MikroTik (MAE-RAV-ROS)

Today (Wednesday) October 11, 2023
7pm to 11pm (Colombia, Ecuador, Peru)

MAE-RAV-ROS-231011