当前位置:文档之家› 动态路由协议RIP与OSPF的配置

动态路由协议RIP与OSPF的配置

海南大学信息科学技术学院实验报告实验名称:动态路由协议RIP与OSPF的配置学号:20 姓名:李新宇班级:电子信息类05班:一、实验目的1、熟悉CISCO IOS和CLI命令模式的使用;2、了解和掌握路由器基本配置命令的使用;3、掌握动态路由协议的配置;4、掌握VLAN中路由器的设置;3.掌握RIP与OSPF路由协议及其配置。

二、实验设备与环境;Windows 2000 Server/Advance Server主机局域网、CISCO Catalyst 2950交换机和2600系列路由器,Cisco Packet Tracer 软件。

三、实验内容课内实验任务(2)实验过程0)创建拓扑图1)采用配置PC1和PC2的IP地址和子网掩码。

2)连接到路由器Router3,配置路由器的RIP,命令如下:(Router>enableRouter#conf terminalRouter(config)#hostname R3R3(config)#interface FastEthernet 0/0R3(config-if)#ip address 11.0.0.1R3(config-if)#no shutdownR3(config-if)#interface FastEthernet 0/1R3(config-if)#ip address 12.0.0.1{R3(config-if)#no shutdownR3(config-if)#interface serial 0R3(config-if)#ip address 10.0.0.1R3(config-if)#bandwidth 128 10.0.011.0.012.0.011.0.0R1(config-router)#endR1(config)#router rip 12.0.0R2(config-router)#end—R2(config)#router rip 10.0.0R4(config-router)#networkR4(config-router)#endR4(config)#rout rip11.0.0R3(config-if)#no shutdownR3(config-if)#interface FastEthernet 0/1 R3(config-if)#ip address 12.0.0.1 R3(config-if)#no shutdown R3(config-if)#interface serial 0 R3(config-if)#ip address 10.0.0.1 *R3(config-if)#bandwidth 128 10.0.0 area 0 11.0.0 area 0 12.0.0 area 0 11.0.0 area 0R1(config-router)#network area 012.0.0 area 0R2(config)#router ospf 10R2(config-router)#network area 0、R2(config-router)#exit10.0.0 area 0R4(config-router)#network 0.0.0.255 area 0Enter configuration commands, one per line. End with CNTL/Z. Router(config)#router ospf 10Router(config-router)#network area 0{Router(config-router)#exitf0/0,f0/0f0/1se0/0 se0/0f0/0f0/1f0/3:IP: 11.0.0.2/24 IP: 11.0.0.1/24 IP: 12.0.0.1/24IP: 12.0.0.2/24IP: 10.0.0.1/24 IP: 10.0.0.2/24IP: /24¥IP: /245)连接到路由器R1中,通过命令“show ip route”显示R1的动态路由表,观察路由表项,当目标网络是/24时,度量值为多少R1>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 2。

E1 - 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 set/24 is subnetted, 1 subnets#O [110/65] via , 00:05:34, FastEthernet0/0/24 is subnetted, 1 subnetsC is directly connected, FastEthernet0/0/24 is subnetted, 1 subnetsO [110/2] via , 00:05:34, FastEthernet0/0O /24 [110/66] via , 00:00:47, FastEthernet0/0答:度量值为66|6)连接到R2、R3和R4,查看每台路由器的路由表。

R2:R2>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 - ODR^P - periodic downloaded static routeGateway of last resort is not set/24 is subnetted, 1 subnetsO [110/65] via , 00:06:26, FastEthernet0/0/24 is subnetted, 1 subnetsO [110/2] via , 00:06:26, FastEthernet0/0`/24 is subnetted, 1 subnetsC is directly connected, FastEthernet0/0O /24 [110/66] via , 00:06:26, FastEthernet0/0R3:R3>show ip routeCodes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP D - 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 - EGP…i - 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 set/24 is subnetted, 1 subnetsC is directly connected, Serial0/0;/24 is subnetted, 1 subnetsC is directly connected, FastEthernet0/0/24 is subnetted, 1 subnetsC is directly connected, FastEthernet0/1O /24 [110/65] via , 00:03:13, Serial0/0//度量值为65R4:Router>show ip route*Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP D - 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 route,Gateway of last resort is not set/24 is subnetted, 1 subnetsC is directly connected, Serial0/0/24 is subnetted, 1 subnetsO [110/65] via , 00:04:12, Serial0/0/24 is subnetted, 1 subnetsO [110/65] via , 00:04:12, Serial0/0<C /24 is directly connected, FastEthernet0/07)使用ping命令测试到路由器各接口的连通状态,以检测路由器的配置。

相关主题