7-2would occur in a loop network and prevents decreased performance of network devices caused byduplicate packets received.In the narrow sense, STP refers to IEEE 802.1d STP; in the broad sense, STP refers to the IEEE 802.1dSTP and various enhanced spanning tree protocols derived from that protocol.Protocol packets of STPSTP uses bridge protocol data units (BPDUs), also known as configuration messages, as its protocolpackets.STP-enabled network devices exchange BPDUs to establish a spanning tree. BPDUs contain sufficientinformation for the network devices to complete spanning tree calculation.In STP, BPDUs come in two types:z Configuration BPDUs, used for calculating a spanning tree and maintaining the spanning treetopology.z Topology change notification (TCN) BPDUs, used for notifying the concerned devices of networktopology changes, if any.Basic concepts in STP1) Root bridgeA tree network must have a root; hence the concept of root bridge was introduced in STP.There is one and only one root bridge in the entire network, and the root bridge can change along withchanges of the network topology. Therefore, the root bridge is not fixed.Upon initialization of a network, each bridge generates and sends out BPDUs periodically with itself asthe root bridge; after network convergence, only the root bridge generates and sends out configurationBPDUs at a certain interval, and the other bridges just forward the BPDUs.2) Root portOn a non-root bridge, the port nearest to the root bridge is called the root port. The root port isresponsible for communication with the root bridge. Each non-root bridge has one and only one rootport. The root bridge has no root port.3) Designated bridge and designated portThe following table describes designated bridges and designated ports.Table 7-1 Description of designated bridges and designated ports:Classification Designated bridge Designated portFor a bridgeA bridge directly connected with the localbridge and forwards BPDUs to the localbridgeThe port through which the designatedbridge forwards BPDUs to this bridgeFor a LAN The bridge that forwards BPDUs to this LANsegmentThe port through which the designatedbridge forwards BPDUs to this LAN segmentAs shown in Figure 7-1, AP1 and AP2, BP1 and BP2, and CP1 and CP2 are ports on Device A, DeviceB, and Device C respectively.z If Device A forwards BPDUs to Device B through AP1, the designated bridge for Device B is DeviceA, and the designated port of Device B is port AP1 on Device A.z Two devices are connected to the LAN: Device B and Device C. If Device B forwards BPDUs to theLAN, the designated bridge for the LAN is Device B, and the designated port for the LAN is the portBP2 on Device B.