meta data for this page
  •  

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
network:switches:cisco:cli:stp [2024/08/19 12:43] – ↷ Page moved from network:switches:cisco:stp to network:switches:cisco:cli:stp niziaknetwork:switches:cisco:cli:stp [2024/08/19 14:19] (current) niziak
Line 1: Line 1:
-====== STP/RSTP ======+====== STP / RSTP ======
  
 ===== getting info ===== ===== getting info =====
  
 <code> <code>
 +show spanning-tree
 +show spanning-tree bridge
 +show spanning-tree detail
 show spanning-tree vlan 28 show spanning-tree vlan 28
 </code> </code>
Line 30: Line 33:
 enable enable
 config terminal config terminal
-Switch(config)#no spanning-tree vlan 1+Switch(config)#no spanning-tree vlan 1-2,28,36,255
 wr wr
 copy run star copy run star
Line 41: Line 44:
 switchport mode dynamic auto switchport mode dynamic auto
 end end
 +</code>
 +
 +===== Inconsistent port type =====
 +
 +Port ''Gi0/48'' is an uplink to another switch:
 +
 +<code>
 +.Aug 19 10:12:00.074: %SPANTREE-7-RECV_1Q_NON_TRUNK: Received 802.1Q BPDU on non trunk GigabitEthernet0/48 VLAN1.
 +.Aug 19 10:12:00.074: %SPANTREE-7-BLOCK_PORT_TYPE: Blocking GigabitEthernet0/48 on VLAN0001. Inconsistent port type.
 +.Aug 19 10:12:18.395: %SPANTREE-2-UNBLOCK_CONSIST_PORT: Unblocking GigabitEthernet0/48 on VLAN0001. Port consistency restored.
 +</code>
 +
 +Setup uplink port as ''trunk''
 +<code>
 +enable
 +conf term
 +interface Gi0/48
 +spanning-tree portfast trunk
 +switchport mode trunk
 +</code>
 +
 +Setup all end-user ports ''0-47'' as:
 +<code>
 +enable
 +conf term
 +interface range Gi0/1-47
 +no switchport mode trunk
 +spanning-tree portfast
 +# optional
 +# don't expect bpdu packets - but it can create loops in LAN!
 +spanning-tree bpdufilter enable
 +spanning-tree bpduguard disable
 </code> </code>