海南大学信息科学技术学院
实验报告
实验名称:动态路由协议RIP与OSPF的配置
学号:_20_姓名:李新宇班级: 电子信息类05班
一、实验目的
1、熟悉CISCO IOS和CLI命令模式的使用;
2、了解和掌握路由器基本配置命令的使用;
3、掌握动态路由协议的配置;
4、掌握VLAN中路由器的设置;
3.掌握RIP与OSPF路由协议及其配置。
二、实验设备与环境
Windows2000 Server/Advanee Server 主机局域网、CISCOCatalyst
2950
交换机和2600系列路由器,Cisco Packet Tracer 软件三、实验内容课内实验任务
(2)实验过程
0)创建拓扑图
26J1XM pc?
Renter? Rnjter4
1)采用配置PC1和PC2的IP地址和子网掩码
2)连接到路由器Router3,配置路由器的RIP,命令如下:
Router〉en able
Router# conf termi nal
Router(c on fig)# host name R3
R3(co nfig)# in terface FastEthernet 0/0
R3(co nfig-if)# ip address 11.0.0.1 shutdow n
R3(config-if)# interface FastEthernet 0/1
R3(config-if)# ip address 12.0.0.1 shutdown
R3(config-if)# interface serial 0
R3(config-if)# ip address 10.0.0.1 128
10.0.0 11.0.0 12.0.0 11.0.0 R1(config-router)# end
R1(config)#router rip 12.0.0
R2(config-router)# end
R4(config-router)# network R2(config)#router rip 10.0.0
rip
PQ21
1 .0.0 shutdow n
R3(c on fig-if)# in terface FastEthernet 0/1
R3(c on fig-
if)#
ip address 12.0.0.1 shutdow n
R3(co nfig-if)# in terface serial 0
R3(co nfig-if)# ip address 10.0.0.1 128 10.0.0 area 0 11.0.0 area 0 12.0.0 area 0 11.0.0 area 0
R1(co nfig-router)# network area 0
12.0.0 area 0
R2(co nfig)#router ospf
10
R2(config-router)#network area 0
R2(config-router)#exit
10.0.0 area 0
R4(config-router)# network 0.0.0.255 area 0
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#router ospf 10
Router(config-router)#network area 0
Router(config-router)#exit
5) 连接到路由器R1中,通过命令“ show ip route ”显示R1的动态路由表,观察路由表项,当目标网络是时,度量值为多少
R1>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 area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2 E1 - 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 - ODR
P - periodic downloaded static route
Gateway of last resort is not set
is subnetted, 1 subnets
O [110/65] via 00:05:34, FastEthernet0/0
is subnetted, 1 subnets
C is directly connected, FastEthernet0/0
is subnetted, 1 subnets
O [110/2] via 00:05:34, FastEthernet0/0
O [110/66] via 00:00:47, FastEthernet0/0
答:度量值为66
6)连接到R2 R3和R4,查看每台路由器的路由表。