ImageVerifierCode 换一换
格式:DOCX , 页数:36 ,大小:84.73KB ,
资源ID:25949865      下载积分:3 金币
快捷下载
登录下载
邮箱/手机:
温馨提示:
快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。 如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝    微信支付   
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【https://www.bdocx.com/down/25949865.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录   QQ登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(实验三 路由协议.docx)为本站会员(b****9)主动上传,冰豆网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知冰豆网(发送邮件至service@bdocx.com或直接QQ联系客服),我们立即给予删除!

实验三 路由协议.docx

1、实验三 路由协议实验三 路由协议3.1 实验目的:1熟悉主机的路由配置;2熟悉路由器的路由配置;3掌握RIP协议的基本配置;4掌握IGRP协议的基本配置;5区别以上两种路由协议的特点。3.2 实验环境实际组网中路由器是用来连接两个物理网络的,为了模拟实际环境,我们在实验中采用背靠背直接相连来模拟广域网连接。由于时间限制,让我们先完成几个简单的背靠背实验,每个对应一个相对独立的内容。如果时间充足,可以完成后面的综合性实验,进一步提高动手能力,深层理解路由协议。下面是简单实验的模拟实验环境,共两台路由器,一台交换机,两台PC。按照上图的实验组网建立实验环境。为了不受路由器原来的配置影响,在实验之前

2、请先将所有路由器的配置数据擦除后重新启动。交换机在此只用作连接主机和路由器用,以便全采用标准网线连接,不需配置。3.3实验步骤:3.3.1静态路由清空路由器的原有配置QuidwayenableQuidway#eraseQuidway#reboot重新启动路由器后,查看初始配置并显示路由表如下:Quidway#show running-config Now create configuration. Current configuration ! version 1.5.6 ! interface Aux0 async mode interactive encapsulation ppp ! i

3、nterface Ethernet0 speed auto duplex auto no loopback ! interface Serial0 encapsulation ppp ! interface Serial1 encapsulation ppp ! endQuidway#show ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop Interface 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBack0 127.0.0.1/32 Direct 0 0 127.0.0.

4、1 LoopBack0配置路由器接口和PC的IP地址路由器各接口的IP地址如下:RTARTBE0202.0.0.1/24202.0.1.1/24S0192.0.0.1/24192.0.0.2/24PC的IP地址和缺省网关Gateway如下:PCAPCBIP202.0.0.2/24202.0.1.2/24Gateway202.0.0.1202.0.1.1为了标识路由器,我们修改路由器名称分别为RTA、RTB并按照上述表格完成IP地址的配置之后,再次查看配置信息和路由表信息如下:RTA#show running-config Now create configuration. Current co

5、nfiguration ! version 1.5.6 hostname RTA ! interface Aux0 async mode interactive encapsulation ppp ! interface Ethernet0 speed auto duplex auto no loopback ip address 202.0.0.1 255.255.255.0 ! interface Serial0 encapsulation ppp ip address 192.0.0.1 255.255.255.0 ! interface Serial1 encapsulation pp

6、p ! endRTA(config-if-Serial0)#show ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop Interface 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBack0 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.0/24 Direct 0 0 192.0.0.2 Serial0 192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.2/32 Di

7、rect 0 0 192.0.0.2 Serial0 202.0.0.0/24 Direct 0 0 202.0.0.1 Ethernet0202.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0RTB的相关信息类似RTA,可以自己在实验中显示比较。注意:串口的配置需要在接口配置模式下完成shutdown和no shutdown命令之后才生效。完成上述配置之后,用ping命令测试网络互通性,会发现两个以太网段不能互通。你知道为什么吗?仔细看看路由表就可以明白,路由器还没有相关的路由项。在这里我们采用配置静态路由的办法来添加路由。分别在RTA,RTB上配置到对端以太

8、网段的静态路由,RTA的配置信息和路由表信息如下:RTA(config)#show running-config Now create configuration. Current configuration ! version 1.5.6 hostname RTA ! interface Aux0 async mode interactive encapsulation ppp ! interface Ethernet0 speed auto duplex auto no loopback ip address 202.0.0.1 255.255.255.0 ! interface Seri

9、al0 encapsulation ppp ip address 192.0.0.1 255.255.255.0 ! interface Serial1 encapsulation ppp ! exit ip route 202.0.1.0 255.255.255.0 192.0.0.2 preference 60 ! endRTA(config)#show ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop Interface 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBack0

10、 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.0/24 Direct 0 0 192.0.0.2 Serial0 192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.2/32 Direct 0 0 192.0.0.2 Serial0 202.0.0.0/24 Direct 0 0 202.0.0.1 Ethernet0 202.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0202.0.1.0/24 Static 60 0 192.0.0.2 Seria

11、l0RTB的相关信息类似RTA。比较前后路由表发现现在新增了一项静态路由,此时再测试网络互通性,可以ping通了吗?3.3.2 RIP协议在上面的实验基础上,删除静态路由的配置之后再启动RIP协议,显示配置信息和路由表信息如下:RTA的配置和路由表:RTA#show running-config Now create configuration. Current configuration ! version 1.5.6 hostname RTA ! interface Aux0 async mode interactive encapsulation ppp ! interface Ethe

12、rnet0 speed auto duplex auto no loopback ip address 202.0.0.1 255.255.255.0 ! interface Serial0 encapsulation ppp ip address 192.0.0.1 255.255.255.0 ! interface Serial1 encapsulation ppp ! exit router rip network all ! endRTA#show ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop In

13、terface 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBack0 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.0/24 Direct 0 0 192.0.0.2 Serial0 192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.2/32 Direct 0 0 192.0.0.2 Serial0 202.0.0.0/24 Direct 0 0 202.0.0.1 Ethernet0 202.0.0.1/32 Direct 0 0 127.0.0.1

14、 LoopBack0202.0.1.0/24 RIP 100 1 192.0.0.2 Serial0RTB的配置和路由表:RTB#show running-config Now create configuration. Current configuration ! version 1.5.6 hostname RTB ! interface Aux0 async mode interactive encapsulation ppp ! interface Ethernet0 speed auto duplex auto no loopback ip address 202.0.1.1 25

15、5.255.255.0 ! interface Serial0 clock-select DTECLK1 encapsulation ppp ip address 192.0.0.2 255.255.255.0 ! interface Serial1 encapsulation ppp ! exit router rip network all ! endRTB#show ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop Interface 127.0.0.0/8 Direct 0 0 127.0.0.1 Lo

16、opBack0 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.0/24 Direct 0 0 192.0.0.1 Serial0 192.0.0.1/32 Direct 0 0 192.0.0.1 Serial0 192.0.0.2/32 Direct 0 0 127.0.0.1 LoopBack0 202.0.0.0/24 RIP 100 1 192.0.0.1 Serial0 202.0.1.0/24 Direct 0 0 202.0.1.1 Ethernet0 202.0.1.1/32 Direct 0 0 127.0.0.1 L

17、oopBack0测试网络互通性,应该是全网互通的。如果不是,请检查您的配置是否与上面的一致。现在我们可以看看RIP是怎样发现路由的,再特权模式下打开RIP协议调试开关,有如下信息在路由器之间传递,它们完成了路由的交换,并形成新的路由。RTA#debug ip rip packet /打开RIP协议调试开关; Rip packet debugging is onRTA#configure Enter configuration commands, one per line. End with command exit!RTA(config)#logging console /使调试信息从cons

18、ole口输出;RTA(config)# RIP: send from 192.0.0.1 to 255.255.255.255(Serial0)Packet:vers 1, cmd Response, length 24 dest 202.0.0.0 ,Metric 1 RIP:receive Response from 192.0.0.2(Serial0)Packet:vers 1, cmd Response, length 24 dest 202.0.1.0 ,Metric 1从上面的信息可以看到RIP协议版本为version 1,这是华为路由器的默认版本。可以用ip rip versio

19、n 2 mcast命令改变协议版本,再查看debug信息如下: RTA#debug ip rip packet Rip packet debugging is onRTA# RIP:receive Response from 192.0.0.2(Serial0)Packet:vers 2, cmd Response, length 24 dest 202.0.1.0 mask 255.255.255.0,router 0.0.0.0 ,metric 1 RIP: send from 192.0.0.1 to 224.0.0.9(Serial0)Packet:vers 2, cmd Respon

20、se, length 24 dest 202.0.0.0 mask 255.255.255.0,router 0.0.0.0 ,metric 1然后使用ip rip version 2 bcast命令改变协议报文的发送方式为广播方式,查看debug信息如下:RTA#debug ip rip packet Rip packet debugging is onRTA# RIP:receive Response from 192.0.0.2(Serial0)Packet:vers 2, cmd Response, length 24 dest 202.0.1.0 mask 255.255.255.0

21、,router 0.0.0.0 ,metric 1 RIP: send from 192.0.0.1 to 255.255.255.255(Serial0)Packet:vers 2, cmd Response, length 24 dest 202.0.0.0 mask 255.255.255.0,router 0.0.0.0 ,metric 1比较以上三种情况的debug信息,能够发现它们的异同吗?广播地址是什么,组播地址又是什么?华为路由器的默认状态启动了水平分割功能,在以上配置基础上,关闭水平分割(RTA(config-if-Serial0)#no ip rip split)再看看de

22、bug信息有什么变化吗?RTA#debug ip rip packet Rip packet debugging is onRTA# RIP:receive Response from 192.0.0.2(Serial0)Packet:vers 2, cmd Response, length 44 dest 202.0.0.0 mask 255.255.255.0,router 0.0.0.0 ,metric 2 dest 202.0.1.0 mask 255.255.255.0,router 0.0.0.0 ,metric 1 RIP: send from 192.0.0.1 to 255.

23、255.255.255(Serial0)Packet:vers 2, cmd Response, length 44 dest 202.0.1.0 mask 255.255.255.0,router 0.0.0.0 ,metric 2 dest 202.0.0.0 mask 255.255.255.0,router 0.0.0.0 ,metric 1我们比较发现关闭水平分割时,交换的路由信息增加了,这就是水平分割的作用。水平分割规定不能将从某一网关送来的路由信息再送回此网关,这就是为什么关闭水平分割时交换的路由信息增加了。下面我们再来理解验证路由器的自动聚合功能。先修改各路由器的E0口的IP地

24、址如下:RTARTBE010.0.1.1/2410.0.2.1/24显示路由器配置信息和路由表信息如下:RTA#show running-config Now create configuration. Current configuration ! version 1.5.6 logging console hostname RTA ! interface Aux0 async mode interactive encapsulation ppp ! interface Ethernet0 speed auto duplex auto no loopback ip address 10.0.

25、1.1 255.255.255.0 ! interface Serial0 encapsulation ppp ip address 192.0.0.1 255.255.255.0 ip rip version 2 bcast ! interface Serial1 encapsulation ppp ! exit router rip network all ! endRTA#show ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop Interface 10.0.1.0/24 Direct 0 0 10.0

26、.1.1 Ethernet0 10.0.1.1/32 Direct 0 0 127.0.0.1 LoopBack0 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBack0 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.0/24 Direct 0 0 192.0.0.2 Serial0 192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0192.0.0.2/32 Direct 0 0 192.0.0.2 Serial0然后在协议配置模式下关闭自动聚合功能,显示路由表信息如下:

27、RTA(config-router-rip)#no auto-summaryRTA(config-router-rip)#show ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop Interface 10.0.1.0/24 Direct 0 0 10.0.1.1 Ethernet0 10.0.1.1/32 Direct 0 0 127.0.0.1 LoopBack0 10.0.2.0/24 RIP 100 1 192.0.0.2 Serial0 127.0.0.0/8 Direct 0 0 127.0.0.1

28、 LoopBack0 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.0/24 Direct 0 0 192.0.0.2 Serial0 192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.2/32 Direct 0 0 192.0.0.2 Serial0比较前后两次的路由表信息,会发现关闭自动聚合功能时增加了一条动态路由,知道为什么吗?然后改变协议版本(ip rip version 1)并使之生效,并在关闭和启动自动聚合功能下显示路由表信息会发现都没有动态路由项产生,知道为什么吗?因为

29、version 1不支持可变长子网掩码,而10.0.1.1与10.0.2.1属于A类地址,自然掩码为8位,属于同一网段的地址。路由表信息如下:RTA(config-if-Serial0)#sho ip routeRouting Tables: Destination/Mask Proto Pref Metric Nexthop Interface 10.0.1.0/24 Direct 0 0 10.0.1.1 Ethernet0 10.0.1.1/32 Direct 0 0 127.0.0.1 LoopBack0 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBac

30、k0 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.0/24 Direct 0 0 192.0.0.2 Serial0 192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0192.0.0.2/32 Direct 0 0 192.0.0.2 Serial0你还可以在接口配置模式下配置命令ip rip version 2 mcast后,显示路由表信息看看又是什么情况。比较上述几种情况下的路由信息,总结version 1和version 2的异同,mcast和bcast的异同以及水平分割和自动聚合的功能。3.3.3 IGRP协议IGRP协议是RIP协议的改进型距离矢量路由协议,但它有更加准确的综合路有权,适用于更大的网络。下面我们就来研究一下IGRP协议,实验环境同上,将路由器和PC的配置恢复到做RIP协议实验之前的配置。然后启动IGRP协议,显示路由器的配置信息和路由表信息如下:RTA的相关信息:RTA#show running-config Now create configuration. Current configuration ! version 1.5.6 loggin

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1