实验四 静动态路由设置实验报告

时间:2024.4.7

实验四/动态路由设置

一、        实验目的

1.       学习静待路由配置方法,理解路由器的工作原理

2.       了解路由器的RIP路由协议的原来;

3.       熟悉掌握路由器的RIP路由协议的配置方法;

4.       了解路由器的OSPF路由协议的原来;

5.       熟悉掌握路由器的OSPF路由协议的配置方法。

二、        实验内容

1.       根据拓扑图链接好所有设备;

2.       综合使用路由器和主机进行静态路由方案的设计;

3.       使用超级终端进行路由配置;

4.       使用PIP路由协议配置路由器的动态路由;

5.       使用OSPF路由协议配置路由器的 动态路由;

6.       相关命令:

   #shiow ip protocols: 显示路由的路由信息

   #show ip route: 显示IP路由表

静态路由:

(config-if)#ip address<本端口IP地址><子网掩码>:为端口设置一个IP地址

(config)#ip route<目的子网地址><子网掩码><相邻路由器端口地址或者本地物理端口号>:设置静态路由

(config)#no ip route<目的子网掩码><子网掩码><相邻路由器端口地址或本地物理端口号>:删除静态路由

RIP:

(config)#router rip:激活RIP路由协议

(config-router)#network<>网段地址>:指明相关联的网段,以便RIP动态学习路由信息

OSPF:

(config)#router ospf<进程号>:激活OSPF路由协议

(config-router)#network<与本路由器相连的ip子网号><通配符>area<区域号>

三、        实验条件:

如图搭建实验环境。

四、        实验过程

1)         配置静态路由:

R2600A#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

C    192.168.1.0/24 is directly connected, Ethernet0/0/0

C    192.168.2.0/24 is directly connected, Ethernet0/1/0

C    192.168.3.0/24 is directly connected, FastEthernet0/0

R2600A#config(设置静态路由

Configuring from terminal, memory, or network [terminal]?

Enter configuration commands, one per line.  End with CNTL/Z.

R2600A(config)#ip route 192.168.4.0 255.255.255.0 192.168.3.2

R2600A(config)#ip route 192.168.5.0 255.255.255.0 192.168.3.2

R2600A(config)#exit

%SYS-5-CONFIG_I: Configured from console by console

R2600A#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

C    192.168.1.0/24 is directly connected, Ethernet0/0/0

C    192.168.2.0/24 is directly connected, Ethernet0/1/0

C    192.168.3.0/24 is directly connected, FastEthernet0/0

S    192.168.4.0/24 [1/0] via 192.168.3.2

S    192.168.5.0/24 [1/0] via 192.168.3.2

R2600A#

对于路由器S2600B进行类似的配合,路由信息如下:

R2600B#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

S    192.168.1.0/24 [1/0] via 192.168.3.1

S    192.168.2.0/24 [1/0] via 192.168.3.1

C    192.168.3.0/24 is directly connected, FastEthernet0/0

C    192.168.4.0/24 is directly connected, Ethernet0/0/0

C    192.168.5.0/24 is directly connected, Ethernet0/1/0

R2600B#

在PC1上检测连通性,如下:

R2600A#config(删除路由器A静态路由

Configuring from terminal, memory, or network [terminal]?

Enter configuration commands, one per line.  End with CNTL/Z.

R2600A(config)#no ip route 192.168.4.0 255.255.255.0

R2600A(config)#no ip route 192.168.5.0 255.255.255.0

R2600A(config)#exit

%SYS-5-CONFIG_I: Configured from console by console

R2600A#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

C    192.168.1.0/24 is directly connected, Ethernet0/0/0

C    192.168.2.0/24 is directly connected, Ethernet0/1/0

C    192.168.3.0/24 is directly connected, FastEthernet0/0

R2600A#

对于路由器B也进行类似操作,请参考路由器A

2)         配置RIP路由协议:

对路由器A

R2600A(config)#no route rip

R2600A#exit

R2600A#config

Configuring from terminal, memory, or network [terminal]?

Enter configuration commands, one per line.  End with CNTL/Z.

R2600A(config)#router rip

R2600A(config-router)#network 192.168.1.0

R2600A(config-router)#network 192.168.2.0

R2600A(config-router)#network 192.168.3.0

R2600A(config-router)#end

%SYS-5-CONFIG_I: Configured from console by console

R2600A#show ip protocols(查看路由器A RIP协议的相关信息

Routing Protocol is "rip"

Sending updates every 30 seconds, next due in 7 seconds

Invalid after 180 seconds, hold down 180, flushed after 240

Outgoing update filter list for all interfaces is not set

Incoming update filter list for all interfaces is not set

Redistributing: rip

Default version control: send version 1, receive any version

  Interface             Send  Recv  Triggered RIP  Key-chain

  Ethernet0/0/0         1     2 1  

  Ethernet0/1/0         1     2 1  

  FastEthernet0/0       1     2 1  

Automatic network summarization is in effect

Maximum path: 4

Routing for Networks:

         192.168.1.0

         192.168.2.0

         192.168.3.0

Passive Interface(s):

Routing Information Sources:

         Gateway         Distance      Last Update

Distance: (default is 120)

对路由器B进行类似的配置,RIP协议的相关信息如下:

R2600B#show ip protocols(查看路由器B RIP协议的相关信息

Routing Protocol is "rip"

Sending updates every 30 seconds, next due in 20 seconds

Invalid after 180 seconds, hold down 180, flushed after 240

Outgoing update filter list for all interfaces is not set

Incoming update filter list for all interfaces is not set

Redistributing: rip

Default version control: send version 1, receive any version

  Interface             Send  Recv  Triggered RIP  Key-chain

  FastEthernet0/0       1     2 1   

  Ethernet0/0/0         1     2 1  

  Ethernet0/1/0         1     2 1  

Automatic network summarization is in effect

Maximum path: 4

Routing for Networks:

         192.168.3.0

         192.168.4.0

         192.168.5.0

Passive Interface(s):

Routing Information Sources:

         Gateway         Distance      Last Update

         192.168.3.1          120      00:00:25

Distance: (default is 120)

Routing Protocol is "ospf 100"

  Outgoing update filter list for all interfaces is not set

  Incoming update filter list for all interfaces is not set

  Router ID 192.168.5.1

  Number of areas in this router is 1. 1 normal 0 stub 0 nssa

  Maximum path: 4

  Routing for Networks:

    192.0.0.0 0.255.255.255 area 200

  Routing Information Sources: 

    Gateway         Distance      Last Update

  Distance: (default is 110)

分别查看路由器A、B的动态路由表

R2600A#show ip route(路由器A的动态路由表

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

C    192.168.1.0/24 is directly connected, Ethernet0/0/0

C    192.168.2.0/24 is directly connected, Ethernet0/1/0

C    192.168.3.0/24 is directly connected, FastEthernet0/0

R    192.168.4.0/24 [120/1] via 192.168.3.2, 00:00:15, FastEthernet0/0

R    192.168.5.0/24 [120/1] via 192.168.3.2, 00:00:15, FastEthernet0/0

R2600A#

R2600B#show ip route(路由器B的动态路由表

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

R    192.168.1.0/24 [120/1] via 192.168.3.1, 00:00:00, FastEthernet0/0

R    192.168.2.0/24 [120/1] via 192.168.3.1, 00:00:00, FastEthernet0/0

C    192.168.3.0/24 is directly connected, FastEthernet0/0

C    192.168.4.0/24 is directly connected, Ethernet0/0/0

C    192.168.5.0/24 is directly connected, Ethernet0/1/0

R2600B#在PC1上检测连通性,结果如下:

删除路由器A、B的RIP路由设置:

R2600A#no router rip

R2600B#no router rip

3)         配置OSPF路由协议:

对路由器A

R2600A#config

Configuring from terminal, memory, or network [terminal]?

Enter configuration commands, one per line.  End with CNTL/Z.

R2600A(config)#router ospf 100

R2600A(config-router)#network 192.168.1.0 0.255.255.255 area 200

R2600A(config-router)#network 192.168.2.0 0.255.255.255 area 200

R2600A(config-router)#network 192.168.3.0 0.255.255.255 area 200

R2600A(config-router)#end

R2600A#show ip protocols(查看A 路由器OSPF协议的相关信息

Routing Protocol is "ospf 100"

  Outgoing update filter list for all interfaces is not set

  Incoming update filter list for all interfaces is not set

  Router ID 192.168.3.1

  Number of areas in this router is 1. 1 normal 0 stub 0 nssa

  Maximum path: 4

  Routing for Networks:

    192.0.0.0 0.255.255.255 area 200

  Routing Information Sources: 

    Gateway         Distance      Last Update

  Distance: (default is 110)

对路由器B进行类似配置:(查看B路由器OSPF协议的相关信息)

R2600B#show ip protocols

Routing Protocol is "ospf 100"

  Outgoing update filter list for all interfaces is not set

  Incoming update filter list for all interfaces is not set

  Router ID 192.168.5.1

  Number of areas in this router is 1. 1 normal 0 stub 0 nssa

  Maximum path: 4

  Routing for Networks:

    192.168.3.0 0.0.0.255 area 200

    192.168.4.0 0.0.0.255 area 200

    192.168.5.0 0.0.0.255 area 200

  Routing Information Sources: 

    Gateway         Distance      Last Update

    192.168.3.1          110      00:01:26

  Distance: (default is 110)

路由器A、B的路由表信息:

R2600A#show ip route(路由器A的路由表信息

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

C    192.168.1.0/24 is directly connected, Ethernet0/0/0

C    192.168.2.0/24 is directly connected, Ethernet0/1/0

C    192.168.3.0/24 is directly connected, FastEthernet0/0

O    192.168.4.0/24 [110/11] via 192.168.3.2, 00:00:57, FastEthernet0/0

O    192.168.5.0/24 [110/11] via 192.168.3.2, 00:00:57, FastEthernet0/0

R2600A#

R2600B#show ip route(路由器B的路由表信息

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

O    192.168.1.0/24 [110/11] via 192.168.3.1, 00:01:43, FastEthernet0/0

O    192.168.2.0/24 [110/11] via 192.168.3.1, 00:01:43, FastEthernet0/0

C    192.168.3.0/24 is directly connected, FastEthernet0/0

C    192.168.4.0/24 is directly connected, Ethernet0/0/0

C    192.168.5.0/24 is directly connected, Ethernet0/1/0

R2600B#

在PC1上测试连通性,结果如下:

五、        实验总结

通过本次试验学会了静/动态路由的配置方法,特别是对RIP协议及OSPF协议的配置方法,同时也让我对路由器内部工作原理有了更进一步的了解。查看路由器的路由表可以了解到现时的工作状态,根据实际的要求对路由器进行设置,在路由表可以及时的显示出来。在试验的过程中也提高了动手能力,为以后的路由器的相关操作打下基础。

更多相关推荐:
计算机网络实验报告 静态路由配置

实验报告八班级姓名学号实验时间机房组号机号PCB一实验题目静态路由配置二实验设备CISCO路由器专用电缆网线CONSOLE线PC机三实验内容了解路由的功能在CISCO路由器上配置和验证静态路由配置缺省路由四原理...

静态路由配置实验报告

配置静态路由一、实验目的(1)掌握静态路由的配置方法。(2)验证静态路由的配置结果,加深对路由概念的理解。二、实验设备(1)路由器、计算机、交换机分别2台(2)console线2根,直通线若干根三、实验过程和主…

静态路由配置实验报告

一实验预习1实验目标了解静态路由掌握静态路由配置2实验原理静态路由需要手工配置信息可以通过路由表路径传输3实验设备及材料2台华为QuidwayAR2811路由器1台PC已安装Iris或网络仿真软件专用配置电缆2...

计算机网络实验报告---静态路由配置

同济大学计算机网络实验课程实验报告题目静态路由器的配置组员专业电气工程及其自动化学生邮箱一实验要求掌握静态路由方式实现网络的连通性二技术原理路由器属于网络层设备能够根据IP包头的信息选择一条最佳路径将数据包装发...

静态路由配置实验报告

静态路由配置实验报告10网络王志龙20xx304020xx4一实验目的掌握路由器的基本使用及配置静态路由二实验内容1给各路由器命名2给路由器及PC配置ip地址3给各路由器配置路由4测试路由是否连通三实验环境及网...

静态路由配置实验报告

深圳大学实验报告课程名称:学院:信息工程学院学号:xx班级:3实验时间:实验报告提交时间:教务处制注:1、报告内的项目或内容设置,可根据实际情况加以调整和补充。2、教师批改学生实验报告时间应在学生提交实验报告时…

《计算机网络》实验六 静态路由配置 实验报告

实验报告六班级07东方信息姓名学号实验时间10年5月17日机房9205组号机号A一实验题目静态路由配置二实验设备CISCO路由器专用电缆网线CONSOLE线PC机三实验内容1了解路由器的功能2在CISCO路由器...

【实验报告】浮动静态路由实验(SLA)_屠双奇

ServiceProfessionalOutstandingTeamwork浮动静态路由SLAV0120xx93SPOTO全球培训项目人才15ServiceProfessionalOutstandingTeam...

实验5 静态路由配置

邢台学院实验报告课程名称网络工程概论实验项目实验5路由器的基本配置以及静态路由配置授课教师刘霞专业班级13网工本1学号20xx0081132学生姓名刘芳系部数学与信息技术学院20xx20xx学年度第2学期实验l...

网络实验 3个路由器的静态路由配置实验

计算机网络实验4B实验名称路由器的基本操作及静态路由配置实验实验目的了解路由器的基本结构功能应用环境以及基本参数的配置实验要求1配置路由器接口的IP地址2设置静态路由3测试静态路由pingIP地址traceIP...

路由器接口及静态路由配置实验报告 2

吴耀宁网络111班3110757111同组实验者黄银才实验四路由器接口及静态路由配置一实验目的1掌握路由器上常见接口的基础配置命令与方法2掌握简单的IP地址规划方法3掌握几个网络之间的静态路由配置方法二预计实验...

实验三:静态路由和默认路由的配置报告

实验三静态路由和默认路由的配置实验目的主要是通过该试验掌握静态路由和默认路由的配置操作方法和验证掌握静态路由的配置场景和默认路由配置的应用背景为今后CCNA的学习打下路由的基础实验要求给定1921681024的...

静态路由实验报告(28篇)