Spanning Tree Protocol Flashcards
What is Spanning Tree Protocol?
It’s a Layer 2 link management protocol that keeps Layer 2 loops from occuring and thus prevents Broadcast Storms
Does Spanning Tree Protocol automate failover?
Yes
How many seconds does it take legacy STP to converge?
~50 seconds
What is a core feature of Spanning Tree Protocol?
It detects potential loops and blocks ports to prevent them
Is a Switch a Multi-Port Bridge
Yes
Switches send these out all ports when they come online and these are used to detect other switches and potential loops
BPDUs (Bridge Protocol Data Units)
What state will a port that first comes online be in?
Blocking state
The BPDU contains this, which will uniquely identify the switch on the LAN
Bridge ID
What is the Bridge ID composed of?
The switch’s unique MAC Address and an administrator defined Bridge Priority value
What can the Bridge Priority range be?
0-65535 but in reality it’s only 0-61440 because it goes in increments of 4096
What is the default Bridge Priority?
32768
What is a Root Bridge elected based on?
Bridge ID values (MAC Address and Bridge Priority Value)
True or False: The switch with the highest bridge priority value is preferred
False. Lowest Bridge Priority value is preferred
In the case of a tie of the Bridge Priority Value, how is a Root Bridge determined?
The switch with the lowest MAC Address will be selected
If you have 4 switches that have not had a Bridge Priority value manually set then what will the Bridge Priority be?
32768
True or False: When a switch calculates its best path towards the Root Bridge, higher bandwidth links are preferred?
True
Each switch’s exit interface on the lowest cost path to the Root Bridge is selected as it’s what?
Root Port
True or False: Spanning Tree Protocol does load balancing?
False
True or False: If a switch has multiple equal cost paths towards the Root Bridge, it will select the neighbor switch with the lowest Bridge ID?
True. It will select it based on the lowest MAC Address or a lower assigned Bridge Priority value
If a switch has multiple equal cost paths via the same neighbor switch towards the Root Bridge, it will select the port with what?
Lowest Port ID going to the lowest Bridge ID
Ports on the neighbor switch opposite the root port are called what?
Designated Ports
Root Ports point toward what?
The Root Bridge
Designated Ports always do what in regards to the Root Bridge?
Point away from it
All ports on the Root Bridge are what?
Designated Ports
The Root Ports and Designated Ports are the most direct path(s) to this?
The Root Bridge
On the remaining links that are not Root Ports or Designated Ports, the switches determine which of them has what?
The least-cost path to the root bridge
Any ports which have not been selected as a Root Port or Designated Port pair would potentially form a loop are called what?
Blocking Ports
When a port is blocked, do BPDUs still get sent out and why or why not?
Yes because they still need to make sure the links are still up otherwise they need to failover
What IEEE standard is STP based on?
IEEE 802.1D
Is RSTP a Cisco Proprietary Version or Open Standard?
Open Standard
What IEEE standard is RSTP?
802.1w
What IEEE standard is MSTP (Multiple Spanning Tree Protocol)?
802.1s
What are the Cisco proprietary versions of modern Spanning Tree?
Per VLAN Spanning Tree Plus (PVST+)
Rapid Per VLAN Spanning Tree Plus (RPVST+)
Does PVST+ allow load balancing?
Yes
What is different between MSTP and PVST+ or RPVST+?
MSTP allows grouping multiple VLANs into different spanning tree instances
PVST+ or RPVST+ do not allow this. You have one spanning tree instance for every VLAN
If you had 20 VLANS on a switch running RPVST+ how many Spanning Tree instances would be running?
- One for every VLAN
What is the default version on most Cisco switches?
PVST+
PVST+ will assign the _____, ______ or _______ role to ports?
Root, Designated or Alternate
Alternate Ports for PVST+ are considered what?
Blocking Ports
What is the Short-Mode Cost of 10Mbps?
100
What is the Short-Mode Cost of 100Mbps?
19
What is the Short-Mode Cost of 1 Gbps?
4
What is the Short-Mode Cost of 10 Gbps?
2
What is the Short-Mode Cost of 20 Gbps?
1
What is the Short-Mode Cost of 100 Gbps?
1
What is the Short-Mode Cost of 1 Tbps?
1
What is the Short-Mode Cost of 10 Tbps?
1
What is the command to verify Spanning Tree?
show spanning-tree {vlan-id}
What version of Spanning Tree is running if the output shows “ieee”
PVST+
On a show spanning tree command, what is the Root ID section telling you about?
Tells you about the Root Bridge, which might not necessarily be the switch you’re looking at the output on
On a show spanning tree command, what is the Bridge ID section telling you about?
This is actually giving you information about the switch you’re running the command on
If you have a switch in a network that is the oldest switch in the network will it be the Root Bridge if all switches in the LAN have a Bridge Priority value of 32768?
Yes. If all switches are defaulted to 32768, then the oldest switch (oldest MAC) will likely become the Root Bridge
How would you manually elect a Root Bridge for VLAN 1?
spanning-tree vlan 1 root primary
How would you manually elect a Secondary Root Bridge for VLAN 1?
spanning-tree vlan 1 root secondary
What value will be given to the Bridge Priority value if the root primary command is used?
24576
What value will be given to the Bridge Priority value if the root secondary command is used?
28672
What command would you use to manually set the Priority Value?
spanning tree {vlan-id} priority {priority-value}
What is the range of valid priority numbers for Spanning Tree?
0-61440
What increment must be used in manual specification for Priority numbers?
4096
If you entered a Priority value of 5000 what would happen?
It would error out since it’s not an increment of 4096
Can you use the primary / secondary commands along with setting a manual Priority value?
No, use one or the other
What is the purpose of STP Portfast?
Used for end host ports because those ports don’t need Layer 2 loop prevention
How would you configure portfast on an access port?
int {int}
spanning-tree portfast
How would you enable portfast globally on a switch?
spanning-tree portfast default
If you do enable portfast by default globally on a switch, what do you need to make sure you do?
Disable the portfast on the interfaces connecting the switches together because they will need to be checking for Layer 2 loops
How would you disable portfast on an interface?
int {int}
no spanning-tree portfast
What is BPDU guard?
This is basically a port that’s been configured as a Portfast port listening for BPDUs coming from any end host on the other side. If a BPDU is received then the switch knows another switch is plugged in on the other side will shut it down immediately because it could potentially form a loop
True or False: Portfast and BPDU Guard should always be used simultaneously?
True
How do you enable BPDU Guard on an access port?
int {int}
spanning-tree bpduguard enable
How do you enable BPDU Guard globally on a switch?
spanning-tree portfast bpduguard default
If a portfast port has been errdisabled by receiving BPDUs what should you do to bring it back?
First, correct the issue
then:
shut
no shut
What is another command other than shut no shut on an int that would bring a portfast port back in service after it’s been shut due to receiving BPDUs?
errdisable recovery cause bpduguard
errdisable recovery interval 30
If you had two switches - one primary and one secondary what command could you use to make sure no other switch ever got introduced that had a superior priority value and thus became the root bridge?
int {int}
spanning-tree guard root
True or False: Spanning Tree Guard Root is enabled at the interface level?
True
What 4 mode states does STP have in order?
Also, what other mode state does it have where the port doesn’t even participate in STP?
Blocking
Listening
Learning
Forwarding
Disabled
Switch port enters the __________ state at time of election process, when a switch receives a BPDU on a port that indicates a better path to the Root Switch or if a port is not a Root Port.
Blocking
In this state, STP determines whether the port should participate in frame forwarding or not.
Listening
Switch port enters _________ state after passing through the listening state as per the decision taken by STP.
Learning
Switch port enters __________ state after passing through all the states involved in creation of network topology.
Forwarding
Switch port enters the _________ state as a result of an administrative command to disable the port.
Disabled
Port does not participate in any operation of STP because it is considered non-operational.
Disabled
Ports receive, process, and transmit BPDUs received from the system module in this mode state.
Learning
________ state is the first transitional state after blocking state.
Listening
Where would you enable Root Guard?
Use Root Guard only on uplink ports that connect to switches or devices that should never become the root bridge. These are typically connections to distribution or core switches.