Comando S Spanning Tree
Comando S Spanning Tree
Comando S Spanning Tree
Refer to page...
16-1 16-38
Commands
ThecommandsusedtoreviewandsetSpanningTreebridgeparametersarelistedbelow. For information about...
show spantree stats show spantree version set spantree version clear spantree version set spantree stpmode clear spantree stpmode show spantree mstilist set spantree msti clear spantree msti
Refer to page...
16-4 16-6 16-6 16-7 16-8 16-8 16-9 16-9 16-10
Matrix X Router Command Line Interface Reference Guide 16-1
Refer to page...
16-10 16-11 16-11 16-12 16-12 16-14 16-15 16-15 16-16 16-17 16-17 16-18 16-18 16-19 16-20 16-20 16-21 16-22 16-22 16-23 16-23 16-24 16-24 16-25 16-25 16-26 16-27 16-27 16-28 16-28 16-29 16-29 16-30 16-30
16-2
Refer to page...
16-31 16-31 16-32 16-32 16-33 16-33 16-34 16-35 16-35 16-37
16-3
Syntax
show spantree stats [port port-string] [sid sid] [active]
Parameters
port portstring sidsid active (Optional)Displaysinformationforthespecifiedports.Foradetailed descriptionofpossibleportstringvalues,refertoPortStringsUsedinthe CLIonpage 102. (Optional)DisplaysinformationforaspecificSpanningTreeidentifier.If notspecified,SID0isassumed. (Optional)DisplaysinformationforportsthathavereceivedSTPBPDUs sinceboot.
Defaults
Ifportstringisnotspecified,noportinformationwillbedisplayed. Ifsidisnotspecified,informationforSpanningTree0willbedisplayed. Ifactiveisnotspecified,informationforallspecifiedportswillbedisplayedregardlessof whetherornottheyhavereceivedBPDUs.
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaysthedevicesSpanningTreeconfiguration.
matrix-x(switch-su)-> show spantree stats Spanning tree status Spanning tree instance Designated Root MacAddr Designated Root Priority Designated Root Cost Designated Root Port Root Max Age Root Hello Time Root Forward Delay Bridge ID MAC Address Bridge ID Priority Bridge Max Age Bridge Hello Time Bridge Forward Delay Topology Change Count Time Since Top Change Max Hops enabled 0 00-00-1d-00-00-01 32768 0 0 20 sec 2 sec 15 sec 00-00-1d-00-00-01 32768 20 sec 2 sec 15 sec 0 00 days 00:08:53 20
Thefollowingtableshowsadetailedexplanationofcommandoutput.
16-4 Spanning Tree Commands
Output
Spanning tree instance Spanning tree status Designated Root MacAddr Designated Root Priority Designated Root Cost Designated Root Port Root Max Age Root Hello Time
What It Displays...
Spanning Tree ID. Mode currently enabled. MAC address of the designated Spanning Tree root bridge. Priority of the designated root bridge. Total path cost to reach the root. Port through which the root bridge can be reached. Amount of time (in seconds) a BPDU packet should be considered valid. Interval (in seconds) at which the root device sends BPDU (Bridge Protocol Data Unit) packets. The device with the highest priority becomes the STA root device. Amount of time (in seconds) the root device spends in listening or learning mode. Unique bridge MAC address, recognized by all bridges in the network. Bridge priority, which is a default value, or is assigned using the set spantree priority command. Maximum time (in seconds) the bridge can wait without receiving a configuration message (bridge hello) before attempting to reconfigure. This is a default value, or is assigned using the set spantree maxage command. Amount of time (in seconds) the bridge sends BPDUs. This is a default value, or is assigned using the set spantree hello command. Amount of time (in seconds) the bridge spends in listening or learning mode. This is a default value, or is assigned using the set spantree fwddelay command. Number of times topology has changed on the bridge. Amount of time (in days, hours, minutes and seconds) since the last topology change. The maximum number of hops that the information for a particular Spanning Tree instance may traverse (via relay of BPDUs within the applicable MST region) before being discarded. This is a default value or is assigned using the set spantree maxhops command.
Root Forward Delay Bridge ID MAC Address Bridge ID Priority Bridge Max Age
16-5
Syntax
show spantree version
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaysSpanningTreeversioninformationforthedevice.
matrix-x(switch-su)-> show spantree version Force Version is mstp
Syntax
set spantree version {mstp | stpcompatible | rstp}
Parameters
mstp stpcompatible rstp SetstheversiontoSTP802.1scompatible. SetstheversiontoSTP802.1Dcompatible. Setstheversionto802.1wcompatible.
Defaults
MSTP.
Mode
Switchcommand,readwrite
16-6
Usage
Inmostnetworks,SpanningTreeversionshouldnotbechangedfromitsdefaultsettingofmstp (MultipleSpanningTreeProtocol)mode.MSTPmodeisfullycompatibleandinteroperablewith legacySTP802.1DandRapidSpanningTree(RSTP)bridges.Settingtheversiontostpcompatible modewillcausethebridgetotransmitonly802.1DBPDUs,andwillpreventnonedgeportsfrom rapidlytransitioningtoforwardingstate.
Example
ThefollowingexamplegloballychangestheSpanningTreeversionfromthedefaultofMSTPto RSTP.
matrix-x(switch-su)->set spantree version rstp
Syntax
clear spantree version
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
ThefollowingexampleresetstheSpanningTreeversion.
matrix-x(switch-su)->clear spantree version
16-7
Syntax
set spantree stpmode {none | ieee8021}
Parameters
none ieee8021
DisablesSpanningTree. Enables802.1SpanningTreemode.
Defaults
IEEE802.1
Mode
Switchcommand,readwrite.
Example
ThefollowingexampledisablesSpanningTree.
matrix-x(switch-su)->set spantree stpmode none
Syntax
clear spantree stpmode
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
ThefollowingexampleresetstheSTPmodetoIEEE802.1.
matrix-x(switch-su)->clear spantree stpmode
16-8
Syntax
show spantree mstilist
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly.
Example
Thisexampleshowsspanningtreeinstance2hasbeenconfigured:
matrix-x(switch-su)-> show spantree mstilist Configured Multiple Spanning Tree Instances: 2
Syntax
set spantree msti sid {create | delete}
Parameters
sid SetstheMultipleSpanningTreeID.Validvaluesare14094. MatrixXRoutersupportsupto32MSTinstances. create|delete CreatesordeletesanMSTinstance.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
ThefollowingexamplecreatesMSTinstance2:
matrix-x(switch-su)-> set spantree msti 2 create
16-9
Syntax
clear spantree msti [sid]
Parameters
sid (Optional)DeletesaspecificmultipleSpanningTreeID.
Defaults
Ifsidisnotspecified,allMSTinstanceswillbecleared.
Mode
Switchcommand,readwrite.
Example
ThefollowingexampledeletesallMSTinstances.
matrix-x(switch-su)-> clear spantree msti
Syntax
show spantree mstmap [fid fid]
Parameters
fidfid (Optional)DisplaysinformationforspecificFIDs.Thevalueoffidcan rangefrom2to4094.
Defaults
Iffidisnotspecified,informationforallassignedFIDswillbedisplayed.
Mode
Switchcommand,readonly.
Usage
Onlynondefaultmappingsaredisplayedbythiscommand.Thatis,nothingmappedtosid0is displayed.
Example
ThefollowingexampledisplaysallnondefaultSIDtoFIDmappinginformation.
16-10 Spanning Tree Commands
matrix-x(switch-su)-> show spantree mstmap Fid 20 is mapped to Sid 3 Fid 40 is mapped to Sid 3 Fid 60 is mapped to Sid 10
Syntax
set spantree mstmap fid [sid sid]
Parameters
fid sidsid SpecifiesoneorarangeofFIDstoassigntotheMST,rangingfrom1to4094,and mustcorrespondtoaVLANIDcreatedusingthesetvlancreatecommand. (Optional)SpecifiesaMultipleSpanningTreeID,rangingfrom1to4094,andmust correspondtoaSIDcreatedusingthesetspantreemsticommand.
Defaults
Ifsidisnotspecified,FID(s)willbemappedtoSpanningTree0.
Mode
Switchcommand,readwrite.
Example
ThefollowingexamplemapsFID3toSID2.
matrix-x(switch-su)-> set spantree mstmap 3 sid 2
Syntax
clear spantree mstmap fid
Parameters
fid
SpecifiesoneormoreFIDstoresetto0,rangingfrom2to4094.
Defaults
Iffidisnotspecified,allSIDtoFIDmappingswillbereset.
16-11
Mode
Switchcommand,readwrite.
Example
ThefollowingexamplemapsFID2backtoSID0:
matrix-x(switch-su)-> clear spantree mstmap 2
Syntax
show spantree vlanlist [vlan-list]
Parameters
vlan-list
(Optional)DisplaysVLANsassignedtospecificSIDs.
Defaults
Ifnotspecified,SIDassignmentwillbedisplayedforallVLANs.
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaystheSIDsmappedtoVLAN2.Inthiscase,SID2ismappedto VLAN2.Forthisinformationtodisplay,theSIDinstancemustbecreatedusingthesetspantree msticommandandtheFIDsmustbemappedtoSID2usingthesetspantreemstmapcommand.
matrix-x(switch-su)-> show spantree vlanlist 2 Vlan 2 is mapped to Sid 2
Syntax
show spantree mstcfgid
Parameters
None.
Defaults
None.
16-12
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaystheMSTconfigurationidentifierelements.Inthiscase,thedefault revisionlevelof0,andthedefaultconfigurationname(astringrepresentingthebridgeMAC address)havenotbeenchanged.Refertothesetspantreemstcfgidcommandforinformationon changingthesesettings.
16-13
matrix-x(switch-su)-> show spantree mstcfgid MST Configuration Identifier: Format Selector: 0 Configuration Name: 00:01:f4:89:51:94 Revision Level: 0 Configuration Digest: ac:36:17:7f:50:28:3c:d4:b8:38:21:d8:ab:26:de:62
Syntax
set spantree mstcfgid {cfgname name | rev level}
Parameters
cfgnamename revlevel SpecifiesanMSTconfigurationname. SpecifiesanMSTrevisionlevel.Validvaluesare065535.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
ThefollowingexamplesetstheMSTconfigurationnametomstconfig.
matrix-x(switch-su)#set spantree mstconfigid cfgname mstconfig
16-14
Syntax
clear spantree mstcfgid
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
ThefollowingexampleresetstheMSTconfigurationidentifierelementstodefaultvalues.
matrix-x(switch-su)#clear spantree mstcfgid
Syntax
set spantree priority priority [sid]
Parameters
priority sid
Defaults
32768priority Ifsidisnotspecified,prioritywillbesetonSpanningTree0.
Mode
Switchcommand,readwrite
Usage
ThedevicewiththehighestprioritybecomestheSpanningTreerootdevice.Ifalldeviceshavethe samepriority,thedevicewiththelowestMACaddresswillthenbecometherootdevice.
Matrix X Router Command Line Interface Reference Guide 16-15
Example
Thefollowingexamplesetsthebridgepriorityto4096onSID1.
matrix-x(switch-su)->set spantree priority 4096 1
Syntax
clear spantree priority [sid]
Parameters
sid
Defaults
Ifsidisnotspecified,prioritywillberesetonSpanningTree0.
Mode
Switchcommand,readwrite.
Example
ThefollowingexampleresetsthebridgepriorityonSID1.
matrix-x(switch-su)->clear spantree priority 1
16-16
Syntax
show spantree bridgehellomode
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaystheSpanningTreebridgehellomode.Inthiscase,asinglebridge hellomodehasbeenenabledusingthesetspantreebridgehellomodecommand.
matrix-x(switch-su)->show spantree bridgehellomode Bridge Hello Mode is currently enabled.
Syntax
set spantree bridgehellomode {enable | disable}
Parameters
enable
disable
Defaults
Enabled.
Mode
Switchcommand,readwrite.
16-17
Usage
Whenbridgehellomodeisenabled,asinglebridgeadministrativehellotimeisused.When bridgehellomodeisdisabled,perportadministrativehellotimesareused.Perporthellotimes canbeconfiguredusingthesetspantreeporthellocommand.
Example
ThefollowingexampledisablessingleSpanningTreehellomodeonthedevice.Perporthello timescannowbeconfiguredusingthesetspantreeporthellocommand:
matrix-x(switch-su)->set spantree bridgehellomode disable
Syntax
clear spantree bridgehellomode
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
ThefollowingexampleresetstheSpanningTreebridgehellomodetoenabled:
matrix-x(switch-su)#clear spantree bridgehellomode
Syntax
set spantree hello sec
Parameters
sec
Defaults
2seconds.
16-18 Spanning Tree Commands
Mode
Switchcommand,readwrite
Usage
TheSpanningTreehellotimeisthetimeinterval(inseconds)thedevicewaitsbetween transmissionsofBPDUsindicatingitisactive.
Example
ThefollowingexamplegloballysetstheSpanningTreehellotimeto10seconds:
matrix-x(switch-su)->set spantree hello 10
Syntax
clear spantree hello
Parameters
None
Defaults
None
Mode
Switchcommand,readwrite
Example
ThefollowingexamplegloballyresetstheSpanningTreehellointerval:
matrix-x(switch-su)->clear spantree hello
16-19
Syntax
set spantree maxage age
Parameters
age
Defaults
20seconds.
Mode
Switchcommand,readwrite
Usage
Thebridgemaximumagingtimeisthemaximumtime(inseconds)adevicecanwaitwithout receivingaconfigurationmessage(bridgehello)beforeattemptingtoreconfigure.Alldevice ports(exceptfordesignatedports)shouldreceiveconfigurationmessagesatregularintervals. AnyportthatagesoutSTPinformationprovidedinthelastconfigurationmessagebecomesthe designatedportfortheattachedLAN.Ifitisarootport,anewrootportisselectedfromamong thedeviceportsattachedtothenetwork.
Example
Thefollowingexamplesetsthemaximumagingtimeto25seconds:
matrix-x(switch-su)-> set spantree maxage 25
Syntax
clear spantree maxage
Parameters
None.
Defaults
None.
16-20
Mode
Switchcommand,readwrite
Example
Thefollowingexamplegloballyresetsthemaximumagingtime:
matrix-x(switch-su)-> clear spantree maxage
Syntax
set spantree fwddelay interval
Parameters
interval
Setstheintervalforthebridgeforwarddelayinseconds.Validvaluesrangefrom4 to30seconds.
Defaults
15seconds.
Mode
Switchcommand,readwrite
Usage
Theforwarddelayvalueisthemaximumtime(inseconds)therootdevicewillwaitbefore changingstates(thatis,fromlisteningstatetolearningstatetoforwardingstate).Thisdelayis requiredbecauseeverydevicemustreceiveinformationabouttopologychangesbeforeitstartsto forwardframes.Inaddition,eachportneedstimetolistenforconflictinginformationthatwould makeitreturntoablockingstate;otherwise,temporarydataloopsmightresult.
Example
Thefollowingexamplegloballysetsthebridgeforwarddelayto16seconds:
matrix-x(switch-su)-> set spantree fwddelay 16
16-21
Syntax
clear spantree fwddelay
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite
Example
Thefollowingexamplegloballyresetsthebridgeforwarddelay:
matrix-x(switch-su)-> clear spantree fwddelay
Syntax
show spantree autoedge
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly
Example
Thefollowingexampledisplaysthestatusoftheautomaticedgeportdetectionfunction:
matrix-x(switch-su)-> show spantree autoedge Auto Edge is set to enable
16-22
Syntax
set spantree autoedge {disable | enable}
Parameters
disable|enable Disablesorenablesautomaticedgeportdetection.
Defaults
Thedefaultisenabled.
Mode
Switchcommand,readwrite
Example
Thefollowingexampledisablesautomaticedgeportdetection:
matrix-x(switch-su)-> set spantree autoedge disable
Syntax
clear spantree autoedge
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite
Example
Thefollowingexampleresetsautomaticedgeportdetectiontoenabled:
matrix-x(switch-su)-> clear spantree autoedge
16-23
Syntax
show spantree legacypathcost
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly
Example
ThefollowingexampledisplaysthedefaultSpanningTreepathcostsetting:
matrix-x(switch-su)-> show spantree legacypathcost Legacy Path Cost is disabled
Syntax
set spantree legacypathcost {disable | enable}
Parameters
disable|enable Enablesordisableslegacy(802.1D)pathcostvalues.
Defaults
Thedefaultisdisabled.
Mode
Switchcommand,readwrite
Usage
Bydefault,legacypathcostisdisabled.Enablingthedevicetocalculatelegacypathcostsaffects therangeofvalidvaluesthatcanbeenteredintheshowspantreeadminpathcostcommand.
Example
Thefollowingexamplesetsthedefaultpathcostvaluesto802.1D:
matrix-x(switch-su)-> set spantree legacypathcost enable
16-24 Spanning Tree Commands
Syntax
clear spantree legacypathcost
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite
Example
Thefollowingexamplesetsthedefaultpathcostvaluesto802.1t:
matrix-x(switch-su)-> clear spantree legacypathcost
Syntax
show spantree tctrapsuppress
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly
Example
Thefollowingexampledisplaysthestatusoftopologychangetrapsuppression:
matrix-x(switch-su)-> show spantree tctrapsuppress Topology change trap suppression is currently enabled.
16-25
Syntax
set spantree tctrapsuppress {disable | enable}
Parameters
disable|enable Disablesorenablestopologychangetrapsuppression.
Defaults
Enabled
Mode
Switchcommand,readwrite
Usage
Bydefault,RSTPnonedge(bridge)portsthattransitiontoforwardingorblockingcausethe switchtoissueatopologychangetrap.Whentopologychangetrapsuppressionisenabled,which isthedevicedefault,edgeports(suchasendstationPCs)arepreventedfromsendingtopology changetraps.Thisisbecausethereisusuallynoneedfornetworkmanagementtomonitoredge portSTPtransitionstates,suchaswhenPCsarepoweredon. Whentopologychangetrapsuppressionisdisabled,allports,includingedgeandbridgeports, willtransmittopologychangetraps.
Example
ThefollowingexampleallowsRapidSpanningTreeedgeportstotransmittopologychangetraps:
matrix-x(switch-su)# set spantree tctrapsuppress disable
16-26
Syntax
clear spantree tctrapsuppress
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite
Example
Thefollowingexampleclearstopologychangetrapsuppressionsettings:
matrix-x(switch-su)# clear spantree tctrapsuppress
Syntax
show spantree txholdcount
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly
Example
Thefollowingexampledisplaysthetransmitholdcountsetting:
matrix-x(switch-su)# show spantree txholdcount Tx hold count is 6
16-27
Syntax
set spantree txholdcount txholdcount
Parameters
txholdcount
Defaults
6
Mode
Switchcommand,readwrite
Example
Thefollowingexamplegloballysetsthetransmitholdcountto5:
matrix-x(switch-su)# set spantree txholdcount 5
Syntax
clear spantree txholdcount
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite
Example
Thefollowingexampleresetsthetransmitholdcount:
matrix-x(switch-su)# clear spantree txholdcount
16-28
Syntax
set spantree maxhops max_hop_count
Parameters
max_hop_count
Setsthemaximumnumberofhopsallowed,rangingfrom0to255.
Defaults
MaxHopcount:20
Mode
Switchcommand,readwrite.
Example
Thefollowingexamplesetsthemaximumhopcountto40:
matrix-x(switch-su)# set spantree maxhops 40
Syntax
clear spantree maxhops
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
Thefollowingexampleresetsthemaximumhopcountto20:
matrix-x(switch-su)# clear spantree maxhops
16-29
Syntax
show spantree spanguard
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly.
Example
Thefollowingexampledisplaysthespanguardfunctionstatus:
matrix-x(switch-su)# show spantree spanguard Span Guard is currently disabled
Syntax
set spantree spanguard {enable | disable}
Parameters
enable|disable Enablesordisablesthespanguardfunction.
Defaults
Disabled.
Mode
Switchcommand,readwrite.
Usage
Whenenabled,thisfunctionpreventsanunauthorizedbridgefrombecomingpartoftheactive SpanningTreetopology.ItdoesthisbydisablingaportthatreceivesaBPDUwhenthatporthas beendefinedasanedge(user)portwiththesetspantreeadminedgecommand.Thisportwill remaindisableduntiltheamountoftime,definedbythesetspantreespanguardtimeout command,haspassedsincethelastseenBPDUortheportismanuallyunlocked,withtheclear spantreespanguardlockcommand.
16-30
Example
Thefollowingexampleenablesthespanguardfunction:
matrix-x(switch-su)# set spantree spanguard enable
Syntax
clear spantree spanguard
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
Thefollowingexampleresetsthestatusofthespanguardfunctiontodisabled:
matrix-x(switch-su)# clear spantree spanguard
Syntax
show spantree spanguardtimeout
Parameters
None.
Defaults
None.
Mode
Switchcommand,readonly.
Example
Thefollowingexampledisplaysthespanguardtimeoutsetting:
matrix-x(switch-su)-> show spantree spanguardtimeout Span Guard Timeout is set at 300 seconds.
Matrix X Router Command Line Interface Reference Guide 16-31
Syntax
set spantree spanguardtimeout timeout
Parameters
timeout
Specifiesatimeoutvalueinseconds.Validvaluesare0(forever)to 65535seconds.
Defaults
300seconds.
Mode
Switchcommand,readwrite.
Example
Thefollowingexamplesetsthespanguardtimeoutto600seconds:
matrix-x(switch-su)#set spantree spanguardtimeout 600
Syntax
clear spantree spanguardtimeout
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
Thefollowingexampleresetsthespanguardtimeoutto300seconds:
matrix-x(switch-su)#clear spantree spanguardtimeout
16-32
Syntax
show spantree spanguardlock port port-string
Parameters
portport-string Specifiestheportsforwhichtoshowspanguardlockstatus.Fora detaileddescriptionofpossibleportstringvalues,refertoPortStrings UsedintheCLIonpage 102.
Defaults
None.
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaysthespanguardlockstatusfortheGigabitEthernetport1inslot4:
matrix-x(switch-su)#show spantree spanguardlock port ge.4.1 Span Guard status for port ge.4.1 is UNLOCKED.
Syntax
clear spantree spanguardlock port-string
Parameters
port-string
Defaults
None.
Mode
Switchcommand,readwrite.
Usage
Whenspanguardisenabled,itlocksportsthatreceiveBPDUswhenthoseportshavebeen definedasedge(user)ports(usingthesetspantreeadminedgecommand).Thecommandset spantreespanguardlockcanalsobeusedtoclearthespanguardlockonaport.
16-33
Example
ThefollowingexampleunlocksalltheGigabitEthernetportsinslot4:
matrix-x(switch-su)# clear spantree spanguardlock ge.4.*
Syntax
set spantree spanguardlock port-string
Parameters
port-string
Defaults
None.
Mode
Switchcommand,readwrite.
Usage
Whenspanguardisenabled,itlocksportsthatreceiveBPDUswhenthoseportshavebeen definedasedge(user)ports(usingthesetspantreeadminedgecommand).Thecommandclear spantreespanguardlockcanalsobeusedtoclearthespanguardlockonaport.
Example
ThefollowingexampleunlocksalltheGigabitEthernetportsinslot4:
matrix-x(switch-su)# set spantree spanguardlock ge.4.*
16-34
Syntax
clear spantree default [sid]
Parameters
sid (Optional)RestoresdefaultsonaspecificSpanningTree.Validvaluesare0 4094.Ifnotspecified,SID0isassumed.
Defaults
Ifsidisnotspecified,defaultswillberestoredonSpanningTree0.
Mode
Switchcommand,readwrite
Example
ThefollowingexamplerestoresSpanningTreedefaultsonSID1:
matrix-x(switch-su)#clear spantree default 1
Syntax
show spantree debug [port port-string] [sid sid] [active]
Parameters
portportstring (Optional)Displaysdebugcountersforspecificports.Foradetailed descriptionofpossibleportstringvalues,refertoPortStringsUsedinthe CLIonpage 102. (Optional)DisplaysthedebugcountersforaspecificSpanningTree identifier.Validvaluesare04094.Ifnotspecified,SID0isassumed. (Optional)Displaysonlythedebugcountersforportsthathavereceivedat leastoneconfigurationorRSTPBPDU.
sidsid active
Defaults
Ifportstringisnotspecified,debugcounterswillbedisplayedforallSpanningTreeports. Ifsidisnotspecified,debugcounterswillbedisplayedforSpanningTree0. Ifactiveisnotspecified,debugcounterswillbedisplayedforactiveandinactiveSpanning Treeports.
16-35
Mode
Switchcommand,readonly
Example
ThefollowingexampledisplaysSpanningTreedebugcountersforlinkaggregationport3,SID0:
matrix-x(switch-su)-> show spantree debug port lag.0.3 STP Diagnostic Common Counters for SID 0 ----------------------------------------Topology Change Count - 379 Message Expiration Count - 16 Invalid BPDU Count - 0 STP BPDU Rx Count - 3 STP BPDU Tx Count - 3 STP TCN BPDU Rx Count - 335 STP TCN BPDU Tx Count - 0 STP TC BPDU Rx Count - 0 STP TC BPDU Tx Count - 0 RST BPDU Rx Count - 81812 RST BPDU Tx Count - 790319 RST TC BPDU Rx Count - 2131 RST TC BPDU Tx Count - 26623 MST BPDU Rx Count - 0 MST BPDU Tx Count - 0 MST CIST TC BPDU Rx Count - 0 MST CIST TC BPDU Tx Count - 0 STP Diagnostic Port Counters for Interface Number lag.0.3 -----------------------------------------------------------Port Role - RootPort Message Expiration Count - 4 Invalid BPDU Count - 0 STP BPDU Rx Count - 0 STP BPDU Tx Count - 0 STP TCN BPDU Rx Count - 0 STP TCN BPDU Tx Count - 0 STP TC BPDU Rx Count - 0 STP TC BPDU Tx Count - 0 RST BPDU Rx Count - 50263 RST BPDU Tx Count - 47602 RST TC BPDU Rx Count - 497 RST TC BPDU Tx Count - 3325 MST BPDU Rx Count - 0 MST BPDU Tx Count - 0 MST CIST TC BPDU Rx Count - 0 MST CIST TC BPDU Tx Count - 0
16-36
Syntax
clear spantree debug
Parameters
None.
Defaults
None.
Mode
Switchcommand,readwrite
Example
ThefollowingexampleclearsSpanningTreedebugcounters:
matrix-x(switch-su)#clear spantree debug
16-37
Commands
ThecommandsusedtoreviewandsetSpanningTreeportparametersarelistedbelow. For information about...
show spantree portenable set spantree portenable clear spantree portenable show spantree portadmin set spantree portadmin clear spantree portadmin set spantree protomigration show spantree portstate show spantree blockedports show spantree portpri set spantree portpri clear spantree portpri set spantree porthello clear spantree porthello show spantree portcost show spantree adminpathcost set spantree adminpathcost clear spantree adminpathcost show spantree adminedge set spantree adminedge clear spantree adminedge show spantree operedge show spantree adminpoint show spantree operpoint
16-38 Spanning Tree Commands
Refer to page...
16-39 16-40 16-40 16-41 16-41 16-42 16-42 16-43 16-44 16-45 16-46 16-46 16-47 16-48 16-49 16-49 16-50 16-51 16-51 16-52 16-53 16-53 16-54 16-54
Refer to page...
16-55 16-56
Syntax
show spantree portenable [port port-string]
Parameters
portportstring (Optional)Displaysstatusforspecificports.Foradetaileddescriptionof possibleportstringvalues,refertoPortStringsUsedintheCLIon page 102.
Defaults
Ifportstringisnotspecified,statuswillbedisplayedforallports.
Mode
Switchcommand,readonly
Example
Thefollowingexampledisplaysstatusforportge.5.12:
matrix-x(switch-su)#show spantree portenable port ge.5.12 Port ge.5.12 has a Port Status of Enabled
16-39
Syntax
set spantree portenable port-string {enable | disable}
Parameters
port-string
enable|disable
Defaults
Enabled.
Mode
Switchcommand,readwrite
Example
ThefollowingexampleenablesSpanningTreeportge.5.12:
matrix-x(switch-su)#set spantree portenable ge.5.12
Syntax
clear spantree portenable [port-string]
Parameters
port-string
Defaults
Ifportstringisnotspecified,portenablewillberesetonallports.
Mode
Switchcommand,readwrite
Example
ThefollowingexampleresetsthedefaultSpanningTreeportstatusvaluetoenabledonten Gigabitport2inslot1:
matrix-x(switch-su)clear spantree portenable tg.2.1
16-40
Syntax
show spantree portadmin [port port-string]
Parameters
portportstring (Optional)Displaysstatusforspecificports.RefertoPortStringsUsedin theCLIonpage 102foradetaileddescriptionofportstringvalues.
Defaults
Ifportstringisnotspecified,statuswillbedisplayedforallports.
Mode
Switchcommand,readonly
Example
ThefollowingexampledisplaysportadminstatusfortenGigabitEthernetport1inslot7:
matrix-x(switch-su)# show spantree portadmin port tg.7.1 Port tg.7.1 has portadmin set to enable
Syntax
set spantree portadmin port-string {disable | enable}
Parameters
port-string
disable|enable
Defaults
Disabled.
Mode
Switchcommand,readwrite
Example
ThefollowingexampledisablesSpanningTreeontenGigabitEthernetport2inslot5:
matrix-x(switch-su)# set spantree portadmin tg.5.2 disable
Matrix X Router Command Line Interface Reference Guide 16-41
Syntax
clear spantree portadmin port-string
Parameters
port-string
Defaults
Disable.
Mode
Switchcommand,readwrite
Example
ThefollowingexampleresetsthedefaultSpanningTreeadminstatetoenableGigabitEthernet port2inslot5:
matrix-x(switch-su)# clear spantree portadmin tg.5.2
Syntax
set spantree protomigration port-string true
Parameters
port-string
true
Defaults
None.
Mode
Switchcommand,readwrite
16-42
Example
ThefollowingexampleresetstheprotocolstatemigrationmachineontenGigabitEthernetport2 inslot5:
matrix-x(switch-su)# set spantree protomigration tg.5.2 true
Syntax
show spantree portstate [port port-string] [sid sid]
Parameters
portportstring (Optional)DisplaystheSpanningTreestateforspecificSpanningTree ports.Foradetaileddescriptionofpossibleportstringvalues,refertoPort StringsUsedintheCLIonpage 102. (Optional)DisplaysthestateforaspecificSpanningTreeidentifier.Valid valuesare04094.Ifnotspecified,SID0isassumed.
sidsid
Defaults
Ifportstringisnotspecified,currentstatewillbedisplayedforallSpanningTreeports. Ifsidisnotspecified,currentportstatewillbedisplayedforSpanningTree0.
Mode
Switchcommand,readonly
Example
ThefollowingexampledisplaystheSpanningTreestatefortenGigabitEthernetport2inslot7:
matrix-x(switch-su)# show spantree portstate port tg.7.2 Port tg.7.2 has a Port State of Forwarding on SID 0
16-43
Syntax
show spantree blockedports [sid]
Parameters
sid (Optional)DisplaysportsonaspecificSpanningTreethatareenabled, havelinkandareblocked,rangingfrom0to4094.
Defaults
Ifsidisnotspecified,blockedportswillbedisplayedforSpanningTree0.
Mode
Switchcommand,readonly.
Usage
Aportinablockedstateisenabledandhaslinkbutdoesnotparticipateinthetransmissionof frames,thuspreventingduplicationarisingthroughmultiplepathsexistingintheactivetopology ofthebridgedLAN.ItreceivesSpanningTreeconfigurationmessages,butdoesnotforward packets.
Example
ThefollowingexampledisplaysblockedportsonSID1:
matrix-x(switch-su)# show spantree blockedports 1 1 ge.5.1 1 ge.5.3 1 ge.5.5 1 ge.5.6 1 ge.5.7 1 ge.5.8 1 ge.5.10 1 ge.5.11 1 ge.5.12 Number of blocked ports in SID 1 : 9
16-44
Syntax
show spantree portpri [port port-string] [sid sid]
Parameters
portportstring (Optional)SpecifiestheportsforwhichtodisplaySpanningTreepriority. Foradetaileddescriptionofpossibleportstringvalues,refertoPortStrings UsedintheCLIonpage 102. (Optional)DisplaysportpriorityforaspecificSpanningTreeidentifier. Validvaluesare04094.Ifnotspecified,SID0isassumed.
sidsid
Defaults
Ifportstringisnotspecified,portprioritywillbedisplayedforallSpanningTreeports. Ifsidisnotspecified,portprioritywillbedisplayedforSpanningTree0.
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaystheportpriorityfortenGigabitEthernetport2inslot7:
matrix-x(switch-su)# show spantree portpri port tg.7.2 Port tg.7.2 has a Port Priority of 128 on SID 0
16-45
Syntax
set spantree portpri port-string priority [sid sid]
Parameters
port-string
priority
sidsid
Defaults
Ifsidisnotspecified,portprioritywillbesetforSpanningTree0.
Mode
Switchcommand,readwrite.
Example
ThefollowingexamplesetsthepriorityofGigabitEthernetport3inslot1to240onSID1.
matrix-x(switch-su)# set spantree portpri ge.1.3 240 sid 1
Syntax
clear spantree portpri port-string [sid sid]
Parameters
portstring SpecifiestheportsforwhichtosetSpanningTreeportpriority.Fora detaileddescriptionofpossibleportstringvalues,refertoPortStrings UsedintheCLIonpage 102. (Optional)ResetstheportpriorityforaspecificSpanningTreeidentifier. Validvaluesare04094.Ifnotspecified,SID0willbeassumed.
sidsid
Defaults
Ifsidisnotspecified,portprioritywillbesetforSpanningTree0.
16-46
Mode
Switchcommand,readwrite.
Example
ThefollowingexampleresetsthepriorityofGigabitEthernetport3inslot1to128onSID1.
matrix-x(switch-su)#clear spantree portpri ge.1.3 sid 1
Syntax
set spantree porthello port-string interval
Parameters
portstring interval Specifiestheportsforwhichtosethellotime. Specifiesthenumberofsecondsthesystemwaitsbeforebroadcastinga bridgehellomessage.Validvaluesare110.
Defaults
2seconds.
Mode
Switchcommand,readwrite.
Usage
ThiscommandsetstheSpanningTreeporthellotime,whichisthetimeintervalinsecondsthe portswilltransmitBPDUs. Thiscommandcanbeexecutedonlyifbridgehellomodeisdisabled.Refertothesetspantree bridgehellomodecommandforinformationaboutdisablingbridgehellomode.
Example
Thefollowingexamplesetsthehellotimeto10secondsforportge.1.4:
matrix-x(switch-su)#set spantree porthello ge.1.4 10
16-47
Syntax
clear spantree porthello port-string
Parameters
portstring Specifiestheportsforwhichtoresethellotime.
Defaults
2seconds
Mode
Switchcommand,readwrite.
Example
Thefollowingexampleresetsthehellotimeto2secondsforportge.1.4:
matrix-x(switch-su)#clear spantree porthello ge.1.4
Syntax
show spantree porthello [port-range]
Parameters
portstring
(Optional)Specifiestheportsforwhichtodisplay.
Defaults
Ifaportstringisnotspecified,thehellotimeforallportsisdisplayed.
Mode
Switch,readonly.
Example
Thefollowingexampleshowstheporthellotimeforallports.
matrix-x(switch-su)-> show spantree porthello Port hello time for port lag.0.1 is 2 seconds. Port hello time for port lag.0.2 is 2 seconds. Port hello time for port lag.0.3 is 2 seconds. Port hello time for port lag.0.4 is 2 seconds. --More-<space> forward, <!> dump all output, <q> quit
16-48
Syntax
show spantree portcost [port port-string] [sid sid]
Parameters
portportstring (Optional)Displayscostvaluesforspecificports.Foradetailed descriptionofpossibleportstringvalues,refertoPortStringsUsedinthe CLIonpage 102 (Optional)DisplaysportcostforaspecificSpanningTreeidentifier.Valid valuesare04094.Ifnotspecified,SID0willbeassumed.
sidsid
Defaults
Ifportstringisnotspecified,portcostwillbedisplayedforallSpanningTreeports. Ifsidisnotspecified,portcostwillbedisplayedforallSpanningTrees.
Mode
Switchcommand,readonly
Example
ThefollowingexampledisplaystheportcostforGigabitEthernetport21inslot7:
matrix-x(switch-su)# show spantree portcost port ge.7.21 Port ge.7.21 has a Port Path Cost of 20000 on SID 0
Syntax
show spantree adminpathcost [port port-string] [sid sid]
Parameters
portportstring (Optional)Displaystheadminpathcostvalueforspecificports.Fora detaileddescriptionofpossibleportstringvalues,refertoPortStrings UsedintheCLIonpage 102. (Optional)DisplaystheadminpathcostforaspecificSpanningTree identifier.Validvaluesare04094.Ifnotspecified,SID0willbeassumed.
sidsid
Defaults
Ifportstringisnotspecified,adminpathcostforallSpanningTreeportswillbedisplayed. Ifsidisnotspecified,adminpathcostforSpanningTree0willbedisplayed.
16-49
Mode
Switchcommand,readonly
Example
ThefollowingexampledisplaystheadminpathcostforGigabitEthernetport10inslot7onSID1:
matrix-x(switch-su)# show spantree adminpathcost port ge.7.10 sid 1 Port ge.7.18 has a Port Admin Path Cost of 0 on SID 1
Syntax
set spantree adminpathcost port-string cost [sid sid]
Parameters
portstring Setstheportsonwhichtosetanadminpathcost.RefertoPortStrings UsedintheCLIonpage 102foradetaileddescriptionofportstring values. Specifiestheportpathcost.Va1idvaluesare: 065535iflegacypathcostisenabled. 0200000000iflegacypathcostisdisabled. sidsid (Optional)SetstheadminpathcostforaspecificSpanningTreeidentifier. Validvaluesare04094.Ifnotspecified,SID0willbeassumed.
cost
Defaults
Ifsidisnotspecified,adminpathcostwillbesetforSpanningTree0.
Mode
Switchcommand,readwrite
Usage
Bydefault,theadminpathcostvalueissetto0,whichforcestheporttorecalculateSpanningTree pathcostbasedonthespeedoftheportandwhetherornotlegacypathcostisenabled.Referto thesetspantreelegacypathcostcommandformoredetails.
Example
Thefollowingexamplesetstheadminpathcostto200forGigabitEthernetport10inslot7onSID 1:
matrix-x(switch-su)# set spantree adminpathcost ge.7.10 200 sid 1
16-50
Syntax
clear spantree adminpathcost port-string [sid sid]
Parameters
portstring Specifiestheportsforwhichtoresetadminpathcost.Foradetailed descriptionofpossibleportstringvalues,refertoPortStringsUsedin theCLIonpage 102. (Optional)ResetstheadminpathcostforspecificSpanningTree. Validvaluesare04094.Ifnotspecified,SID0isassumed.
sidsid
Defaults
Ifsidisnotspecified,adminpathcostwillberesetforSpanningTree0.
Mode
Switchcommand,readwrite
Usage
ThiscommandwillforceSpanningTreepathcosttoberecalculatedonspecifiedportsbasedon whetherornotsetspantreelegacypathcostisenabled.
Example
Thefollowingexampleresetstheadminpathcostto0forport10inslot7onSID1:
matrix-x(switch-su)# clear spantree adminpathcost ge.7.10 sid 1
Syntax
show spantree adminedge port-string
Parameters
portstring Specifiestheportsforwhichtodisplayedgeportadministrative status.Foradetaileddescriptionofpossibleportstringvalues, refertoPortStringsUsedintheCLIonpage 102.
Defaults
None.
16-51
Mode
Switchcommand,readonly
Example
ThefollowingexampledisplaystheedgeportstatusfortenGigabitport2inslot1:
matrix-x(switch-su)# show spantree adminedge tg.1.2 Port tg.1.2 has a Port Admin Edge of Edge-Port
Syntax
set spantree adminedge port-string {true | false}
Parameters
port-string
true|false
Defaults
None.
Mode
Switchcommand,readwrite.
Example
ThefollowingexamplesetsGigabitEthernetport11inslot1asanedgeport:
matrix-x(switch-su)# set spantree adminedge ge.1.11 true
16-52
Syntax
clear spantree adminedge port-string
Parameters
portstring Specifiesportsonwhichtoresetedgeportstatus.Foradetaileddescription ofpossibleportstringvalues,refertoPortStringsUsedintheCLIon page 102.
Defaults
None.
Mode
Switchcommand,readwrite.
Example
Thefollowingexampleresetsport11inslot1asanonedgeport:
matrix-x(switch-su)# clear spantree adminedge ge.1.11
Syntax
show spantree operedge [port port-string]
Parameters
portportstring (Optional)Displaysedgeportoperatingstatusforspecificports.SeePort StringsUsedintheCLIonpage 102foradescriptionofportstring values.
Defaults
IfportstringisnotspecifiededgeportoperatingstatuswillbedisplayedforallSpanningTree ports.
Mode
Switchcommand,readonly.
Example
Thefollowingexampledisplaystheedgeportstatusforport21inslot7:
matrix-x(switch-su)# show spantree operedge port ge.7.21
Matrix X Router Command Line Interface Reference Guide 16-53
Syntax
show spantree adminpoint [port port-string]
Parameters
portportstring (Optional)Displayspointtopointstatusforspecificports.Foradetailed descriptionofpossibleportstringvalues,refertoPortStringsUsedinthe CLIonpage 102.
Defaults
Ifportstringisnotspecified,statuswillbedisplayedforallSpanningTreeports.
Mode
Switchcommand,readonly.
Example
ThefollowingexampledisplaysthepointtopointstatusoftheLANsegmentattachedtoport21 inslot7.
matrix-x(switch-su)# show spantree adminpoint port ge.7.21 Port ge.7.21 has a Port Admin Point to Point of Auto
Syntax
show spantree operpoint [port port-string]
Parameters
portportstring (Optional)Displayspointtopointoperatingstatusforspecificports.Fora detaileddescriptionofpossibleportstringvalues,refertoPortStringsUsed intheCLIonpage 102.
Defaults
Ifnotspecified,statuswillbedisplayedforallports.
Mode
Switchcommand,readonly.
16-54
Example
ThefollowingexampledisplaysthepointtopointstatusoperatingoftheLANsegmentattached toport21inslot7.
matrix-x(switch-su)# show spantree operpoint port ge.7.21 Port fg.7.21 has a Port Oper Point to Point of False on SID 1
Syntax
set spantree adminpoint port-string {true | false | auto}
Parameters
portstring Specifiestheportonwhichtosetpointtopointprotocolstatus.Fora detaileddescriptionofpossibleportstringvalues,refertoPortStringsUsed intheCLIonpage 102. SpecifiesthepointtopointstatusoftheLANattachedtothespecifiedport. trueforcestheporttobeconsideredpointtopoint. falseforcestheporttobeconsiderednonpointtopoint. auto(thedefaultsetting)allowsthefirmwaretodeterminetheports pointtopointstatus.
true|false|auto
Mode
Switchcommand,readwrite.
Example
ThefollowingexamplesetstheLANattachedtoport3inslot1asapointtopointsegment.
matrix-x(switch-su)# set spantree adminpoint ge.1.3 true
16-55
Syntax
clear spantree adminpoint [port-string]
Parameters
portstring (Optional)Resetspointtopointprotocolstatusonspecificports.Fora detaileddescriptionofpossibleportstringvalues,refertoPortStringsUsed intheCLIonpage 102.
Defaults
Ifportstringisnotspecified,pointtopointstatuswillberesetforallSpanningTreeports.
Mode
Switchcommand,readwrite.
Example
ThefollowingexampleresetsallportsonallSpanningTreestoautopointtopointstatus.
matrix-x(switch-su)# clear spantree adminpoint
16-56