《RIP-综合实验.docx》由会员分享,可在线阅读,更多相关《RIP-综合实验.docx(12页珍藏版)》请在课桌文档上搜索。
1、1.o120.1.1.2/24R2WWW2CTO.COMkRI,R2,R3,R4运行RlPY22、Rl以广播的形式发送路由给20.I.3.0的路由10、R2上看到5.5.5.0的路由为IO跳11.R5向RIPja告一条一认路由R2(confi)isinterface1.OOPbaCk3R2(config-if)#ipaddress20.1.3.2255.255.255.0R2(confi)8intf00R2(config-if)ipadd12.1.1.2255.255.255.0R2(config-if)noshutdownR2(config-if)Bdup1exful1R-I(Config)
2、Sinterfaceloopback1R4(configif)=ipadd4.4.4.4255.255.255.0R4(config)#intf00R4(confi-if)tfipadd12.1,1.4255.255.255.0Rl(config-if)SnoshutdownR4(config-if)OduplexfullRIconfi)Rintl00RKconfigif)Sipadd12.1.1.1255.255.255.0RKconfigif)SnoshutdownR2(config-if)Sduplexful1Rl(confi-if)i11tcrfacesl/1Rl(confi-if)4
3、ipadd13.1.1.1255.255.255.OIU(config-if)ttnoshutdownR3(config)Rintsl/1R3(config-if)ipadd13.1.1.3255.255.255.0R3(co11figif)#noshutR3(configif)Pintsl0R3(config-if)ipadd35.1.1,3255.255.255.0R3(config-if)nushutdownR5(config)#interfaceloopback1R5(config-if)Oipadd5.5.5.5255.255.255.0R5(config)9intsl0R5(nfi
4、g-if)Sipadd35.1.1.5255.255.255.0R5(co11figif)Pnoshutdown按以上配置好后,运用口in吩时确保网络连通性正常。kR1.R2、R3、Rl运行RIPV2R2(config)#routerrip#启用RlP协议R2(confi-router)vcrsion2#启用RlPV2版本R2(config-router)network.0宣告主类网段R2(config-router)network12.0.0.0R2(config-router)Rnoauto-su三nary#不发自动汇总路由Rl(config)SrouterripR4(confi-rout
5、er)Svorsion2R4(config-rouler)nauto-suwnaryR4(config-routor)Itnetwork4.0.O.ORl(config-router)network12.O.O.ORI(config)UrouterripRl(config-router)Aversion2Rl(configrouter)noautoSUBfnnryRl(configrouter)network12.O.O.ORKconfig-routcr)Snetwork13.O.O.OR3(config)UrouterripR3(config-router)Aversion2R3(confi
6、g-router)Onoaut-sunmnryR3(config-router)network13.O.O.OR3(configrouter)#network35.O.O.O2. Rl以广播的形式发送路由送.O网段Rl(Config)Uint00RKconfigif)=ipripv2broadcast#接口下以广播的形式发送版本2的史新Rl(configif),dodebugiprip*启用debug询试路由更新.可看到RI在F0/0口上运用广揄更新Sep620:36:08.895:RIP:sendingv2updateto255.255.255.255viaFastEthernetOZO(1
7、2.1.1.1)Sep620:36:08.895:RIP:buiIdupdateentries*S叩620:36:08.895:13.1.1.0/24viaO.O.O.O.metricI.tagOSep620:36:08,895:35.1.1.0/24viaO.O.O.O.metric2tagO3、R5运行RlPWR5(config)RrouterripR5(config-router)CverR5(co11figrouter)version1R5(configrouter)network此时在R5Ng看路由只有宜连接路由:其它路由器上没有R5的路由。缘由在R5上运行的是Vl版本行I只收发运行
8、VI路由),其它路由器上运行的是V2(V2只收发运行V2路由解决的方法是:在接口下限刎发送接收的更新版本路由。可见后面明细路由时的配4、R1.R2R4所在的.0网段进行MD5认证Rl(config)Ukeychaincisco定义钥匙链名称,只有本地意义,路由器之间的keychain可以不同R1(config-keychain)Rkey1。指定Key-IDteRl(configkeychainkey)Skeystringtgh二指定Key密码,路由器之间的KeyString要保持一样R1(confiJrkcychain-key)#exitRKconfi-koychain)cxitRl(conf
9、ig)intf00Rl(config-if)ipripauthenticationmW-三obile,B-BGPD-ElGRP,EX-EIGRPexternal.0-OSPF,IA-OSPFinterareaNl-OSITNSSAexternaltype1,N2-OSITNSSAexternaltype2EI-OSPFexternaltype1.E2-OSPFexternaltype2i-IS-IS.su-IS-ISs三nary,1.l-IS-ISlevel-1,1.2-IS-ISIeveI-2iaISISinterarea.Candidntedefault.Uperuserstaticrou
10、teoODR,P-periodicdownloadedstaticrouteGatewayoflastresortisnotset35. 0.0.0/24issubS-static*R-RIP,M-BobilaB-BGPD-EIGRHEX-EIGRPexternal.O-GSPF,IA-OSPFinterareaNl-OSITNSSAexternaltype1,N2-OSITNSSAexternaltype2El-OSPFexternaltypeI1E2-OSITexternaltype2i-IS-IS.su-IS-ISsuninary,1.l-IS-ISlevel-l,1.2-IS-ISIe
11、ve1-2ia-IS-ISinterarea,-candidatedefau11,U-per-userstaticrouteoODR,P-periodicdownloadedstaticrouteGatewayoflastresortisnotset35.0.0.0/24issubnettcd1subnetsC35.1.1.0isdirectlyconnected.SerialI/O.0/24issubnetted,1subnetsR4.4,4,0120/2vi.1,00:00:01,Serial1/120.0.0.0/16issubnetted,1subnets*此时到的是一条20.1.0.
12、0/16汇总路由R20.1.0.0120/2vi.1,00:00:01,Seriall/l12.0.0.0/24isSubfietlcd11subnetsR.0120/1vi.1,00:00:01.Seriall/113.0.0.0/24isSUbnetted,1subnetsC13.1.1.0isdirectlyconnected,Seriall/17RUR3之间尽少的更新R3(cnfi)*i11lsl/1:触发更新是只在拓扑发生改变的状况下才发送路由更新信息,平常不会周期性发送路由更新R3(config-if)0ipriptriggered才接口下开E触发更新,只适用在申行链跖,且两边要同
13、时开启,否则无效。有改变才更新,适合于低带宽钺路Rl(config)intsl/1Rl(configif)fipriptriggered8、R3,R5之间不能有广播和组播更新R3(config)UrouterripR3(config-router)eneighbor35.1.1.5R3(configrouter)passiveinterfacesl/O二指定RIP以单播的形式发送更新给指定的邻居.passive只关闭广播和组播不能关闭单播R5(cnfig)#routertipR5(config-router)Oneighbor35.1.1.3R5(config-router)Opassive-
14、interfacesl/O9、R4上不能看到.020.1.3.0的路由IM(config)WoshowiprouteCodes:C-connected,S-static,R-RIP,M-三obile,B-BGPI)-EIGRP,EX-EIGRPexternal.0-OSPF,IA-OSPFinterareaNl-OSpFxSSRexternaltypeI,N2-OSPFNSSAexternaltype2El-OSPFexternaltypeltE2OSPFexternaltype2iISIS.suISISsuamary.1.lIS-ISlevel1.1-2IS-ISlevel2ia-IS-IS
15、interarea,calidatcdefau11,U-Pe1.USCrSlatiCrOUtCo-ODR,P-periodicdownloadedstaticrouteGatewayoflastresortisnotset35.0.0.0/24isSUbnetled,1subnets35.1.1.0120/2vi.1,00:00:01,FastEthernetOZO1.0.0.02lissubnetted,IsubnetsI.I.I.0i:-dirtct!yconnected.I.oop!,.:subnets20.0.0.0/24issubnetted.320.1.1.0120/1vi.2,0
16、0:00:02.FastEthernetOZO20.1.3.0120/1vi.200:00:02,FasiEihcrnelOZO20.1.2.0120/1vi.2,00:00:02,FastElhernctOZO5.0.0.0/24issubnetted,1subnets5.5,5,0120/3vi.1,00:00:01,FastEthernetOZO12. 0.O.0/21issulnetted,1subnets1. .1.1.0isdirectlyconnected.FastEthernetOZO13.00.0/24issubnetted.1subnets13.1.1.0120/1vi3通
17、过将管理冲圈值设为255从而使M上不再有20.1.0,0段的路由R4(confirouter)#distance25520.I.2,2255.255.255.0Rl(config-router)Mistance25520.1.3.2255.255.255.0M(config-router)MocleariprouteRl(config-router)CdoshowiprouteCodes:C-connected,S-staticvR-RIP,M-BobiIe,B-BGPDEIGRP.EXEIGRPexternal.0OSPF.IOSPFinterareaNlOSPFNSSexternaltyp
18、e1.N2OSPFNSSexternaltype2El-OSPFexternaltypeI1E2-OSPFexternaltype2i-IS-IS1su-IS-ISs三ary1.l-IS-ISlevel-l,1.2-ISTSIcve1-2ia-IS-ISinterarea,-candidatedefault,U-per-userstaticrouteo-ODR,P-eriodicdownloadedstaticrouteGatewayoflastresortisnotset35.0.0.0/24issulnetted.1subnets35. 1.1.0120/2vi.1.00:00:06,Fa
19、stEthernetOZO1.0.0.0/21issubnetted,1subnetsR5.5.5,0120/3vi.100:00:06FaslEthorneiOZO12.0.0.0/24isSulxietted,1subnetsC12.1.1.0isdirectlyconnected,FastEthernetOZO13. 0.0.0/24issuletted,1subnetsR13.1.1.0120/1vi.1,00:00:06,FastEthernetOZO1也可通过偏移列表实现J10、R2上看到0的路由为10跳R2(config-router)OdoshowiprouteCodes:C-
20、connected,S-static,R-RIP,M-nobiIe,B-BGPD-EIGRPfcEX-EIGRPexternal.0-OSPF,IOSPFinterareaNl-OSPFNSSexternaltype1.N2OSPFXSSAexternaltype2El-OSPFexternaltype1.E2-OSPFexternaltype2i-IS-IS.su-IS-ISsu三ary,1.l-IS-ISlevel-1,1.2-IS-ISICVCI-2ia-IS-ISinterarea,-candidatedefault,U-per-userstaticrouteo-ODR,P-perio
21、dicdownloadedstaticrouteGatewayoflastresortisnotset35. 0.0.0/24issulmetted,1subnetsR35.1.1.0120/2vi.1.00:00:23.FastEthernetOZO36. 0.0.02,lissubnetted,1subnetsR4.4,4,0120/1vi.4,00:00:06.FaslElhernetOZO20. 0.0.0/24issub3subnetsC20.1.1.0isdirectlyconnected,1.OOPbaCklC20.1.3.0isdirectlyconnected,1.oOPba
22、Ck3C20.1.2.0isdirectlyconnected.1.(K)PbaCk237. 0.0.021issubnetted,1subnetsR5.5.5.0120/3vi.1.00:00:23.FastEthernetOXO#数认为3跳12. 0.0,0z24issublettcd1subnets13. O.O.O21issubnetlcd1subnetsR13.1.1.0120/1vi#运用偏移更表R2(config)WrouterriR2(config-router)Ooffset-1ist1in7口由于默认为3跳此处再偏移7跳即可R2(config-router)Pdoclear
23、iprouteR2(config-roulcr)doshowiprouteCodes:C-connected,S-sialic,R-RIPW-三obile,B-BGPD-EIGRP,EX-EIGRPexternal.0-OSPF,IA-OSPFinterareaNl-OSITNSSAexternaltype1,N2-OSITNSSAexternaltype2EI-OSPFexternaltype1.E2-OSPFexternaltype2i-IS-IS.su-IS-ISs三nary,1.l-IS-ISlevel-1,1.2-IS-ISIeveI-2iaISISinterarea.Candidn
24、tedefault,UperuserstaticrouteoODR,P*periodicdownloadedstaticrouteGatewayoflastresortisnotset35.0.0.0/24isSubnetted91subnets35.1.1.0120/2vi.1,00:00:04,FastEthernetOZO1.0.0.0/21issubnetted,1subnetsEastBthernetOZO4. 4.4.0120vi.4f00:00:04.3subnets20.0.0.0/24isSUbnCtted.20.1.1.0isdirectlyconnected.1.oopb
25、ackl20.1.3.0isdirectlyconnected.1.oopback320.1.2.0isdirectlyconnected.1.oopback25.0.0.0/24issubnetted,1subnets5. 5,5.0120/10vi.I,00:00:04.FastEthernetOZO变为10跳12. 0.0.0/24issuletted,1subnetsC12.1.1.0isdirectlyconnected,FastEthernetO/O13.0.0.0/21issubnetted,1subnetsR13.1.1.0120/1vi.1,00:00:00.FastEthe
26、rnetOZOIkR5向RIP通话条熟认路由R5(config)RrouterripR5(config-router)defau11-informationoriginate2利用路由协议自动下发默认路由给全盘路由器R3(config-router)#docleariprouteR3(config-router)MoshowipruteCodes:C-connected,S-static,R-RIP,M-aobilelB-BGPO-ElGRP,EX-EIGRPexternal.O-OSPF,IA-OSPFinterareaNl-OSpFNSSAexternaltype1,N2-OSPFNSSA
27、externaltype2El-OSPFexternaltype1.E2-OSPFexternaltype2iIS-IS.suISISsu11mary.1.lIS-ISlevel1.1.2IS-ISlevel2iaISISinterarea,Candidatedefnult.Uperuserstaticrouteo-OCR,P-periodicdownloadedstaticrouteGatewayoflastresortis35.1.1.5tonetwork.035.0.0.0/24issul)netted,1subnetsC35.1-1.0isdirectlyconnected,Seria
28、l1/0.0/24issubnetted.1subnetsR4.4.4O120/2vi.1.00:00:53,Serial1/120.0.0.0/16issubnetted.1subnetsR20.1.0.0120/2vi.1.00:00:53,Seriall/l5.0.0.0/24isSubricltedlIsubnetsR5.5,5,0120/1via35.1.1.5.00:00:01,Sriall012.0.0.0/24isSUbnetted,1subnetsR12.1.1.0120/1vi.1,00:00:54,Serial1/113.0.0.0/24isSulxietted,1subnetsC13.1.1.0isdirectlyconnected,Serial1/1R*0.0.0.0/0120/1via35.1.1.5,00:00:01.Serial1/0#R1.R2、R3、R4上均有带R*的路由#让RIP区域生成默认路由的方法有多种,上面只举一例