当前位置:文档之家› RIP_路由协议的配置

RIP_路由协议的配置

RIP 路由协议的配置一、实验目的1、复习路由器的三种模式及口令管理2、练习RIP 动态路由协议的基本配置;3、掌握了解RIP 路由协议原理二、实验环境:Cisco Packet Tracer三、关于RIP 的基础知识RIP(Routing Information Protocol)是最常使用的内部网关协议(Interior Gateway Protocol)之一,是一种典型的基于D-V 算法的动态路由协议。

通过UDP(User Datagram Protocol)报文交换路由信息,使用跳数(Hop Count)来衡量到达目的地的距离(被称为路由权-Routing cost)。

由于在RIP 中大于或等于16 的跳数被定义为无穷大(即目的网络或主机不可达),所以RIP 一般用于采用同类技术的中等规模的网络,如校园网及一个地区范围内的网络,RIP 并非为复杂、大型的网络而设计。

启动RIP,进入RIP 视图:router Rip关闭RIP:no rip在指定的网络上使能RIP network{ network-number| all }在指定的网络上禁用RIP no network{ network-number| all四:实验步骤:绘制拓扑图如下所示(为每个路由器添加一个WIC-2T模块):配置过程:Router1:Router>enable //进入特权模式Router#conf ter //进入全局配置模式Enter configuration commands, one per line. End with CNTL/Z.Router(config)#int f0/0 //配置Fa0/0 接口Router(config-if)#ip add 1.1.1.2 255.255.255.0Router(config-if)#no shutdown%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to upRouter(config-if)#%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to upRouter(config-if)#exitRouter(config)#int s0/0/0 //配置串口Router(config-if)#ip add 1.1.6.1 255.255.255.0Router(config-if)#no shutdown%LINK-5-CHANGED: Interface Serial0/0/0, changed state to downRouter(config-if)#exitRouter(config)#int s0/0/1 //配置串口Router(config-if)#ip add 1.1.2.1 255.255.255.0Router(config-if)#no shutdown%LINK-5-CHANGED: Interface Serial0/0/1, changed state to downRouter(config-if)#exitRouter(config)#router rip //进入RIP 视图Router(config-router)#network 1.0.0.0 //发布直连网络Router(config-router)#exitRouter(config)#exitRouter#%SYS-5-CONFIG_I: Configured from console by consoleRouter#show ip route //查看路由表Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area * - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not set1.0.0.0/24 is subnetted, 1 subnetsC 1.1.1.0 is directly connected, FastEthernet0/0Router#Router2:Router>enableRouter#conf terEnter configuration commands, one per line. End with CNTL/Z.Router(config)#int f0/0Router(config-if)#ip add 1.1.5.2 255.255.255.0Router(config-if)#no shutdown%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to upRouter(config-if)#exitRouter(config)#int s0/0/1Router(config-if)#ip add 1.1.2.2 255.255.255.0Router(config-if)#clock rate 64000Router(config-if)#no shutdown%LINK-5-CHANGED: Interface Serial0/0/1, changed state to upRouter(config-if)#exitRouter(config)#int s0/0/0Router(config-if)#ip add 1.1.3.1 255.255.255.0Router(config-if)#no shutdown%LINK-5-CHANGED: Interface Serial0/0/0, changed state to downRouter(config-if)#exitRouter(config)#router ripRouter(config-router)#network 1.0.0.0Router(config-router)#exitRouter(config)#exitRouter#%SYS-5-CONFIG_I: Configured from console by consoleRouter#Router#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area* - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not set1.0.0.0/24 is subnetted, 3 subnetsR 1.1.1.0 [120/1] via 1.1.2.1, 00:00:11, Serial0/0/1C 1.1.2.0 is directly connected, Serial0/0/1C 1.1.5.0 is directly connected, FastEthernet0/0Router#Router3:Router>enRouter#conf terEnter configuration commands, one per line. End with CNTL/Z.Router(config)#int f0/0Router(config-if)#ip add 1.1.4.2 255.255.255.0Router(config-if)#no shutdown%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to upRouter(config-if)#exitRouter(config)#int s0/0/0Router(config-if)#ip add 1.1.6.2 255.255.255.0Router(config-if)#clo rate 64000Router(config-if)#no shutdownRouter(config-if)#%LINK-5-CHANGED: Interface Serial0/0/0, changed state to upRouter(config-if)#exitRouter(config)#int s0/0/1Router(config-if)#ip add 1.1.3.2 255.255.255.0Router(config-if)#clock rate 64000Router(config-if)#no shutdown%LINK-5-CHANGED: Interface Serial0/0/1, changed state to upRouter(config-if)#exitRouter(config)#router ripRouter(config-router)#%LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0/1, changed state to up Router(config-router)#network 1.0.0.0Router(config-router)#exitRouter(config)#exitRouter#%SYS-5-CONFIG_I: Configured from console by consoleRouter#show ip rouRouter#show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGPD - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter areaN1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGPi - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area * - candidate default, U - per-user static route, o - ODRP - periodic downloaded static routeGateway of last resort is not set1.0.0.0/24 is subnetted, 6 subnetsR 1.1.1.0 [120/1] via 1.1.6.1, 00:00:02, Serial0/0/0R 1.1.2.0 [120/1] via 1.1.6.1, 00:00:02, Serial0/0/0[120/1] via 1.1.3.1, 00:00:10, Serial0/0/1C 1.1.3.0 is directly connected, Serial0/0/1C 1.1.4.0 is directly connected, FastEthernet0/0R 1.1.5.0 [120/1] via 1.1.3.1, 00:00:10, Serial0/0/1C 1.1.6.0 is directly connected, Serial0/0/0之后按照图示配置好主机的IP 地址,使用ping 命令测试相互之间的连通性.附:路由器口令管理如果用户没有在路由器的控制台上设置口令,其他用户就可以访问用户模式,并且,如果没有设置其它模式的口令,别人也就可以轻松进入其它模式。

相关主题