Home > Cisco, Switching > Configuring Spanning Tree

Configuring Spanning Tree

show spanning-tree
conf t
spanning-tree vlan 50 <== turns spanning tree on vlan 50
spanning-tree vlan 50 priority root primary <== make switch primary root, priority 24626
show spanning-tree vlan 50

# Modifying weight of spanning tree for a particular VLAN (load balancing)
conf t
int fa0/14
spanning-tree vlan 50 cost 4 <== sets the cost for this particular vlan
show spanning-tree blockedports <== show forwarded/blocked ports may change from new vlan cost

# Portfast
conf t
int fa0/5
spanning-tree portfast <== puts port in FWD mode, bypassing 35s STP process
# Protection from misconfiguration of port for portfast
conf t
spanning-tree portfast bpduguard <== if it sees BPDU packets, it will disable the port
spanning-tree portfast bpdufilter <== ignores BPDU packets
spanning-tree portfast default <== use with caution, enables portfast on all access ports

# Uplinkfast (Cisco proprietary, replaced by 802.1W rapid STP)
Places all ports going to same destination in uplink groups
If root port fails, transition is made to another port in the group
Takes ~5s to failover

conf t
spanning-tree uplinkfast

# Backbonefast (Cisco proprietary, replaced by 802.1W rapid STP)
If a switch with a port to the Root Port fails on that port, it may start generating ROOT BPDUs. The neighbor with Backbonefast configured will tell that switch that isn't the case and correct it.

conf t
spanning-tree backbonefast

# Rapid STP (backwards compat with 802.1d, on by default)
less states: discarding, learning, forwarding (blocking, listening are gone)
additional port roles: root port, designated port, alternate port, backup port, disabled port

conf t
spanning-tree mode rapid-pvst

Categories: Cisco, Switching
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: