Two Key Spanning-Tree Protocol Concepts

Two Key Spanning-Tree Protocol Concepts

Spanning Tree calculations make extensive use of two key concepts when creating a loop-free logical topology:

  • Bridge ID (BID)
  • Path Cost

Bridge IDs

A Bridge ID (BID) is a single, 8-byte field that is composed of two subfields as illustrated in Figure 6-5.

Figure 6-5. The Bridge ID (BID) Is Composed of Bridge Priority and a MAC Address
two-key-spanning-tree-protocol-concepts-6.5

The low-order subfield consists of a 6-byte MAC address assigned to the switch. The Catalyst 5000 and 6000 use one of the MAC addresses from the pool of 1024 addresses assigned to every supervisor or backplane. This is a hard-coded number that is not designed to be changed by the user. The MAC address in the BID is expressed in the usual hexadecimal (base 16) format.

  • Note
    Some Catalysts pull the MAC addresses from the supervisor module (for example, the Catalyst 5000), whereas others pull the addresses from the backplane (such as the Catalyst 5500 and 6000).

The high-order BID subfield is referred to as the Bridge Priority. Do not confuse Bridge Priority with the various versions of Port Priority that are discussed in Chapter 7, “Advanced Spanning Tree.” The Bridge Priority field is a 2-byte (16-bit) value. The C programmers in the crowd might recall that an unsigned 16-bit integer can have 216 possible values that range from 0–65,535. The default Bridge Priority is the mid-point value, 32,768. Bridge Priorities are typically expressed in a decimal (base 10) format.

  • Note
    This book only covers the IEEE version of the Spanning-Tree Protocol. Although the basic mechanics of both are identical, there are some differences between IEEE STP and DEC STP (the original implementation of the Spanning-Tree Protocol). For example, DEC STP uses an 8-bit Bridge Priority. Layer 2 Catalysts (such as the 4000s, 5000s, and 6000s) only support IEEE STP. Cisco routers support both varieties. A third variety, the VLAN-Bridge Spanning Tree, is being introduced in 12.0 IOS code for the routers. This version can be useful in environments that mix routing and bridging and is discussed in Chapter 11.

Path Cost

Bridges use the concept of cost to evaluate how close they are to other bridges. 802.1D originally defined cost as 1000 Mbps divided by the bandwidth of the link in Mbps. For example, a 10BaseT link has a cost of 100 (1000/10), Fast Ethernet and FDDI use a cost of 10 (1000/100). This scheme has served the world well since Radia Perlman first began working on the protocol in 1983.

However, with the rise of Gigabit Ethernet and OC-48 ATM (2.4 Gbps), a problem has come up because the cost is stored as an integer value that cannot carry fractional costs. For example, OC-48 ATM results in 1000 Mbps/2400 Mbps=.41667, an invalid cost value. One option is to use a cost of 1 for all links equal to or greater than 1 Gbps; however, this prevents STP from accurately choosing “the best path” in Gigabit networks.

As a solution to this dilemma, the IEEE has decided to modify cost to use a non-linear scale. Table 6-1 lists the new cost values.

Table 6-1. STP Cost Values for Network Bridges

BandwidthSTP Cost
4 Mbps250
10 Mbps100
16 Mbps62
45 Mbps39
100 Mbps19
155 Mbps14
622 Mbps6
1 Gbps4
10 Gbps2

The values in Table 6-1 were carefully chosen so that the old and new schemes interoperate for the link speeds in common use today.

The key point to remember concerning STP cost values is that lower costs are better. Also keep in mind that Versions 1.X through 2.4 of the Catalyst 5000 NMP use the old, linear values, whereas version 3.1 and later use the newer values. All Catalyst 4000s and 6000s utilize the new values.

About the author

Scott

Leave a Comment