Bridge protocol data unit

From Hill2dot0

(Redirected from BPDU)
Jump to: navigation, search

Switches configure a spanning tree by exchanging information and making calculations. The information is exchanged in a special message called a bridge protocol data unit (BPDU). Each BPDU contains the information necessary to configure and maintain the spanning tree topology. BPDUs are not forwarded by switches. Instead, their information is used by a switch to calculate its own BPDU for transmission.

There are two types of BPDUs defined for use in STP: Configuration BPDUs and Topology Change Notification BPDUs. The former is used to establish and maintain the spanning tree. The latter is used to notify switches when the topology has been changed.

BPDUs are generated by the bridge management protocol and are carried in the Data field of the media access control (MAC) frame. The MAC frame uses a reserved destination group address, as defined in IEEE 802.1D, Section 3. This reserved group address is recognized only by switches supporting STP.

Configuration BPDUs

Configuration BPDUs
Enlarge
Configuration BPDUs

Configuration Bridge Protocol Data Units (BPDU) are exchanged by switches connected to the same collision domain or point-to-point link to compute and configure the spanning tree. The accompanying visual depicts the Configuration BPDU packet format. Below is a description of each field.

  • Protocol Identifier: A two-octet field that identifies the Spanning Tree Protocol (STP). The field is set to a value of 0000 0000 0000 0000.
  • Protocol Version Identifier: A one-octet field that identifies the current version of the protocol being used, which was specified in the previous field. For the STP, this field is set to a value of 0000 0000.
  • BPDU Type: A one-octet field that identifies the type of BPDU being sent. This is set to a value of 0000 0000 for a Configuration BPDU.
  • Flags: A one-octet field that contains flags used in response to a Topology Change Notification BPDU. Bit 1 is the Topology Change flag. It is used by the root to tell all switches to speed up their aging timers for their filtering databases. Bit 8 is designated as the Topology Change Acknowledgment flag. It is used by a switch receiving a Topology Change Notification BPDU to acknowledge receipt to the transmitting switch.
  • Root Identifier: An eight-octet field that contains the bridge identifier of the root for the spanning tree being deployed.
  • Root Path Cost: A four-octet field used to indicate the cost of the path from the transmitting switch to the root.
  • Bridge Identifier: An eight-octet field containing the bridge identifier of the transmitting switch.
  • Port Identifier: A two-octet field used to identify the port via which this BPDU was transmitted.
  • Message Age: A two-octet field used to indicate the age of the current Configuration BPDU. This parameter allows a receiving switch to discard a BPDU that exceeds Max Age.
  • Max Age: A two-octet field used to indicate a timeout value to be used by all switches in the broadcast domain. The Max Age value is set by the root.
  • Hello Time: A two-octet field defining the time interval between generation of Configuration BPDUs by the root. It is used to facilitate the monitoring of protocol performance by management functions.
  • Forward Delay: A two-octet field that defines the time a switch port must wait in the listening state, and then again in the learning state, before entering the forwarding state.

Topology Change Notification BPDU

Topology Change Notification BPDU
Enlarge
Topology Change Notification BPDU

In the normal, stable operation of the spanning tree, MAC address information in the switch's filtering database need only change as a result of physically relocating a LAN adapter or adding a new one. It may then be desirable to set a long aging timer for entries in the filtering database to reduce excessive updates.

However, when the active spanning tree topology reconfigures in the event of a failure, LAN adapters may appear to move from the point of view of the switch without having physically changed locations. MAC addresses must be relearned following a change. In this case, a short timeout value would be better.

To strike a balance between these two needs, the topology change notification (TCN) BPDU is used. When a switch that is not the root changes the active topology, it transmits a TCN BPDU on its root port. A switch receiving a TCN BPDU responds with a Configuration BPDU with the topology change acknowledgment flag set to a 1, acknowledging receipt of the frame, and transmits a TCN BPDU on its root port. This propagates up the tree until it reaches the root. When the root receives the TCN BPDU, it sends out a Configuration BPDU message on all of its ports with the Topology Change flag set to a 1. Each switch receiving a Configuration BPDU on its root port with the topology change flag set empties its filtering database immediately and then generates its own configuration BPDU on each of its designated ports with the topology change flag set. This propagates down the tree to the ends of each path. This speeds up their aging timers temporarily, so any changes are quickly relearned.

The accompanying visual depicts the Topology Change Notification BPDU packet format. Below are the descriptions for the fields listed.

  • Protocol Identifier: A two-octet field that identifies the STP. The field is set to a value of 0000 0000 0000 0000.
  • Protocol Version Identifier: A one-octet field that identifies the current version of the protocol being used, which was specified in the previous field. For the STP, this field is set to a value of 0000 0000.
  • BPDU Type: Same as in configuration BPDU, except the value of the field is set to 1000 0000 to indicate this is a Topology Change Notification BPDU.
Personal tools
Hill Associates Sites