Configuring the Spanning Tree Protocol 651Configuring Optional STP FeaturesBeginning in Privileged EXEC mode, use the following commands toconfigure the optional STP features on the switch or on specific interfaces.show spanning-tree[detail] [active |blockedports]View information about spanning tree and the spanningtree configuration on the switch.Command Purposeconfigure Enter global configuration mode.spanning-tree bpdufloodingAllow the flooding of BPDUs received on non-spanning-tree ports to all other non-spanning-tree ports.spanning-tree portfast Enable PortFast on all switch ports.spanning-tree portfastbpdufilter defaultPrevent ports configured in PortFast mode from sendingBPDUs.spanning-tree loopguarddefaultEnable loop guard on all ports.spanning-tree bpdu-protectionEnable BPDU protection on the switch.interfaceinterface Enter interface configuration mode for the specifiedinterface. Theinterface variable includes the interface typeand number, for example gigabitethernet 1/0/3 or port-channel 4.You can also specify a range of interfaces with the interfacerange command, for example, interface rangegigabitethernet 1/0/8-12 configures interfaces 8, 9, 10, 11,and 12. The range keyword is also valid for LAGs (portchannels).spanning-tree auto-portfastSet the port to auto portfast mode. This enables the portto become a portfast port if it does not see any BPDUs for3 seconds.spanning-tree guard{root | loop | none}Enable loop guard or root guard (or disable both) on theinterface.Command Purpose