STP Lab 31 32.docx
《STP Lab 31 32.docx》由会员分享,可在线阅读,更多相关《STP Lab 31 32.docx(33页珍藏版)》请在冰豆网上搜索。
![STP Lab 31 32.docx](https://file1.bdocx.com/fileroot1/2023-4/17/e7cfd171-d956-43e2-895e-0622ed6ff5a4/e7cfd171-d956-43e2-895e-0622ed6ff5a41.gif)
STPLab3132
Lab3-1SpanningTreeProtocol(STP)DefaultBehavior
Objective
ThepurposeofthislabistoobservethedefaultbehaviorofSTP.
Scenario
Fourswitcheshavejustbeeninstalled.Thedistributionlayerswitchesare
Catalyst3560s,andtheaccesslayerswitchesareCatalyst2960s.Thereare
redundantuplinksbetweentheaccesslayeranddistributionlayer.Becauseof
thepossibilityofbridgingloops,spanningtreelogicallyremovesanyredundant
links.Inthislab,youwillobservewhatspanningtreedoesandwhy.
Step1
RefertoLab2.0“ClearingaSwitch”toprepareallfourswitchesforthislab.
Cabletheequipmentasshown.Ifyouareaccessingyourequipmentremotely,
askyourinstructorforinstructionsonhowtodothis.Configurethefourswitches
asshowninthediagramwithahostname,password,andconsolesecurity.
ConnecttoDLS1andenterthefollowingcommands:
Switch>enable
Switch#configureterminal
Switch(config)#hostnameDLS1
DLS1(config)#enablesecretclass
DLS1(config)#lineconsole0
DLS1(config-line)#passwordcisco
DLS1(config-line)#login
ConnecttoDLS2andenterthefollowingcommands:
2-6CCNP:
BuildingMultilayerSwitchedNetworksv5.0-Lab3-1Copyright©2006,CiscoSystems,Inc
Switch>enable
Switch#configureterminal
Switch(config)#hostnameDLS2
DLS2(config)#enablesecretclass
DLS2(config)#lineconsole0
DLS2(config-line)#passwordcisco
DLS2(config-line)#login
ConnecttoALS1andenterthefollowingcommands:
Switch>enable
Switch#configureterminal
Switch(config)#hostnameALS1
ALS1(config)#enablesecretclass
ALS1(config)#lineconsole0
ALS1(config-line)#passwordcisco
ALS1(config-line)#login
ConnecttoALS2andenterthefollowingcommands:
Switch>enable
Switch#configureterminal
Switch(config)#hostnameALS2
ALS2(config)#enablesecretclass
ALS2(config)#lineconsole0
ALS2(config-line)#passwordcisco
ALS2(config-line)#login
Step2
Afterthecablesareconnectedandtheswitchdetectstheredundantlinks,
spanningtreeisinitiated.
Bydefault,spanningtreerunsoneveryport.Whenanewlinkbecomesactive,
theportgoesthroughthelistening,learning,andforwardingstatesbeforeit
becomesactive.Duringthisperiod,theswitchdiscoversifitisconnectedto
anotherswitchoranend-userdevice.
Ifanotherswitchisdetected,thetwoswitchesbegincreatingaspanningtree.
Oneoftheswitchesiselectedastherootofthetree.Thenanagreementis
establishedastowhichlinkstokeepactiveandwhichlinkstodisableifmultiple
linksexist.
1.WhattypeofframedoesSTPusetocommunicatewithotherswitches?
NoteTheresultsinthislabwillvary.Spanningtreeoperationisbased
ontheMACaddressoftheswitches.
ObservetheLEDsontheswitchtocheckthestatusofthelink.Abrightgreen
lightindicatesanactivelink.Anamberlightindicatesaninactivelink.
3-6CCNP:
BuildingMultilayerSwitchedNetworksv5.0-Lab3-1Copyright©2006,CiscoSystems,Inc
Step3
VerifySTPwiththeshowspanning-treecommandonDLS1:
DLS1#showspanning-tree
VLAN0001
Spanningtreeenabledprotocolieee
RootIDPriority32769
Address000a.b8a9.d680
Cost19
Port13(FastEthernet0/11)
HelloTime2secMaxAge20secForwardDelay15sec
BridgeIDPriority32769(priority32768sys-id-ext1)
Address000a.b8a9.d780
HelloTime2secMaxAge20secForwardDelay15sec
AgingTime300
InterfaceRoleStsCostPrio.NbrType
--------------------------------------------------------------------
--
Fa0/7DesgFWD19128.9P2p
Fa0/8DesgFWD19128.10P2p
Fa0/9DesgFWD19128.11P2p
Fa0/10DesgFWD19128.12P2p
Fa0/11RootFWD19128.13P2p
Fa0/12AltnBLK19128.14P2p
VerifySTPwiththeshowspanning-treecommandonDLS2:
DLS2#showspanning-tree
VLAN0001
Spanningtreeenabledprotocolieee
RootIDPriority32769
Address000a.b8a9.d680
Thisbridgeistheroot
HelloTime2secMaxAge20secForwardDelay15sec
BridgeIDPriority32769(priority32768sys-id-ext1)
Address000a.b8a9.d680
HelloTime2secMaxAge20secForwardDelay15sec
AgingTime300
InterfaceRoleStsCostPrio.NbrType
--------------------------------------------------------------------
--
Fa0/7DesgFWD19128.9P2p
Fa0/8DesgFWD19128.10P2p
Fa0/9DesgFWD19128.11P2p
Fa0/10DesgFWD19128.12P2p
Fa0/11DesgFWD19128.13P2p
Fa0/12DesgFWD19128.14P2p
VerifySTPwiththeshowspanning-treecommandonALS1:
ALS1#showspanning-tree
VLAN0001
Spanningtreeenabledprotocolieee
RootIDPriority32769
4-6CCNP:
BuildingMultilayerSwitchedNetworksv5.0-Lab3-1Copyright©2006,CiscoSystems,Inc
Address000a.b8a9.d680
Cost19
Port11(FastEthernet0/9)
HelloTime2secMaxAge20secForwardDelay15sec
BridgeIDPriority32769(priority32768sys-id-ext1)
Address0019.0635.5780
HelloTime2secMaxAge20secForwardDelay15sec
AgingTime300
InterfaceRoleStsCost
1d22h:
%SYS-5-CONFIG_I:
ConfiguredfromconsolebyconsolePrio.Nbr
Type
--------------------------------------------------------------------
--
Fa0/7AltnBLK19128.9P2p
Fa0/8AltnBLK19128.10P2p
Fa0/9RootFWD19128.11P2p
Fa0/10AltnBLK19128.12P2p
Fa0/11DesgFWD19128.13P2p
Fa0/12DesgFWD19128.14P2p
VerifySTPwiththeshowspanning-treecommandonALS2:
ALS2#showspanning-tree
VLAN0001
Spanningtreeenabledprotocolieee
RootIDPriority32769
Address000a.b8a9.d680
Cost19
Port9(FastEthernet0/7)
HelloTime2secMaxAge20secForwardDelay15sec
BridgeIDPriority32769(priority32768sys-id-ext1)
Address0019.068d.6980
HelloTime2secMaxAge20secForwardDelay15sec
AgingTime300
InterfaceRoleStsCost
1d22h:
%SYS-5-CONFIG_I:
ConfiguredfromconsolebyconsolePrio.Nbr
Type
--------------------------------------------------------------------
--
Fa0/7RootFWD19128.9P2p
Fa0/8AltnBLK19128.10P2p
Fa0/9AltnBLK19128.11P2p
Fa0/10AltnBLK19128.12P2p
Fa0/11AltnBLK19128.13P2p
Fa0/12AltnBLK19128.14P2p
Noticethatbetweentwoswitches,oneofthetwoportsissettoblocking.
Blockingcouldoccurontheaccesslayerswitchorthedistributionlayerswitch.If
allportshavetheirdefaultsetting,thehigherinterfacenumberofthetwoportsis
settoblocking.
Theswitchportisinblockingstatebecauseitdetectedtwolinksbetweenthe
sameswitches.Thiswouldresultinabridgeloopiftheswitchlogicallydisables
onelink.
5-6CCNP:
BuildingMultilayerSwitchedNetworksv5.0-Lab3-1Copyright©2006,CiscoSystems,Inc
NoteYouroutputmaydiffer,becauseallswitcheshavethedefault
bridgepriorityof32769andselectionoftherootbridgeisbased
uponthelowestswitchMACaddress.Thesampleoutputbelow
mayalsodifferfromthoseinyourlab,becausetheywere
generatedwithadifferentsetofswitches.
DLS2#showspanning-tree
VLAN0001
Spanningtreeenabledprotocolieee
RootIDPriority32769
Address000a.b8a9.d680
Thisbridgeistheroot
HelloTime2secMaxAge20secForwardDelay15sec
BridgeIDPriority32769(priority32768sys-id-ext1)
Address000a.b8a9.d680
HelloTime2secMaxAge20secForwardDelay15sec
AgingTime300
InterfaceRoleStsCostPrio.NbrType
--------------------------------------------------------------------
--
Fa0/7DesgFWD19128.9P2p
Fa0/8DesgFWD19128.10P2p
Fa0/9DesgFWD19128.11P2p
Fa0/10DesgFWD19128.12P2p
Fa0/11DesgFWD19128.13P2p
Fa0/12DesgFWD19128.14P2p
Afterreviewingthespanningtreeoutput,answerthefollowingquestions.
1.Whichswitchistherootofthespanningtree?
2.Howcantherootswitchbeidentified?
3.Whywasthatswitchselectedastheroot?
6-6CCNP:
BuildingMultilayerSwitchedNetworksv5.0-Lab3-1Copyright©2006,CiscoSystems,Inc
4.Whatcausedoneporttobeinblockingstateoveranother?
5.Whatcausedonelinktobeblockedoveranother?
Step4
CreateadiagramofthespanningtreetopologyforVLAN01.WithCiscoCatalyst
switches,thereisadifferentspanningtreestateforeachVLAN.Identifytheroot
bridge,rootports,anddesignatedports.
Inthislab,thedefaultoperationofspanningtreewasobserved.Sincenobridge
prioritieswerespecified,theswitchwiththelowestMACaddresswaselectedas
theroot.Sincenolinkprioritieswerechanged,thelinkwiththelowestcostwas
chosenastheactivelink.Ifcostswereequal,thetiewasbrokenbythelowest
portnumber.
Inalaterlab,thedefaultSTPbehaviorwillbemodifiedsothatspanningtree
worksaccordingtospecifications.
Challenge
Trytoguesshowyourtopologywouldlookifyoucompletelyremovedtheroot
switch.RememberthattheswitchwiththelowestMACaddressbecomesthe
root.
Now,shutdownalltheportsonyourcurrentrootswitch.Usetheshow
spanning-treecommandontheotherswitches.Didthetopologyconvergethe
wayyouthoughtitwould?
1-12CCNP:
BuildingMultilayerSwitchedNetworksv5.0-Lab3-2Copyright©2006,CiscoSystems,Inc
Lab3-2ModifyingDefaultSpanningTreeBehavior
Objective
Thepurposeofthislabistoobservewhathappenswhenthedefaultspanning
treebehaviorismodified.
Scenario
Fourswitcheshavejustbeeninstalled.Thedistributionlayerswitchesare
Catalyst3560s,andtheaccesslayerswitchesareCatalyst2960s.Thereare
redundantuplinksbetweentheaccesslayeranddistributionlayer.Becauseof
thepossibilityofbridgingloops,spanningtreelogicallyremovesanyredundant
links.Inthislab,youwillseewhathappenswhenthedefaultspanningtree
behaviorismodified.
Step1
Startbydeletingvlan.dat,erasingthestartupconfiguration,andreloadingyour
switches.Afterreloadingtheswitches,givethemhostnames.Youcanfind
detailedinstructionsinLab2.0.
Step2
Us