2 RIP协议的基本配置( 三 )


R 172.16.2.0 (.120/21 via 17246.13.1, 00:00:04,Serial0
C 172.16.3.01s directly connected, Ethernet0
R3#trace 172.16.2.2
Type escape sequence to abort.
Tracing the route to 172.16.2.2
1 172.16.13.14 msec 4 msec 8 msec
2 172.16.12.2 16 msec 8 msec*
R3#conft
Enter configuration commands,one per line.End with CNTL/Z.
R3(config)#int s1
R3(ocnfig-if)#no sh
R3(config-if)#exit
R3(config)#logg con
R3(config)#exit
R3#de
01:29:45:%SYS-5CONFIG_I:Configured from console by console
R3:debug ip rip
RIP protocol debugging is on
R3#
01:29:56:RIP:sending v1 update to 255.255.255.255 via Ethernet0(172.16.3.3)
01:29:56:RIP:build update entries
01:29:56: subnet 172.16.1.0 metric 2
01:29:56: subnet 172.16.2.0 metric 2
01:29:56: subnet 172.16.12.0 metric 2
01:29:56: subnet 172.16.13.0 metric 1
01:29:56: subnet 172.16.23.0 metric 1
01:29:56: RIP: sending v1 update to 255.255.255.255 via Serial0 (172.16.13.3)
01:29:56: RIP: build update entries
01:29:56: subnet 172.16.2.0 metric 2
01:29:56: subnet 172.16.3.0 metric 1
01:29:56: subnet 172.16.23.0 metric 1
01:29:56: RIP: sending v1 update to 255.255.255.255 via Serial1 (172.16.23.3)
01:29:56: RIP: build update entries
01:29:56: subnet 172.16.1.0 metric 2
01:29:56: subnet 172.16.3.0 metric 1
01:29:56: subnet 172.16.13.0 metric 1
01:30:00: RIP: received v1 update from 172.16.23.2 on Serial1
01:30:00: 172.16.1.0 in 2 hops
01:30:00: 172.16.2.0 in 1 hops
01:30:00: 172.16.12.0 in 1 hops
R3#
01:30:07: RIP: received v1 update from 172.16.13.1 on Serial0
01:30:07: 172.16.1.0 in 1 hops
01:30:07: 172.16.2.0 in 2 hops
01:30:07: 172.16.12.0 in 1 hops
R3-#indebug all
(1)show ip protocol命令的执行结果中包含了有关RIP协议的大量信息,主要有:各种计时器信息;
版本信息,发送version 1,接收任何version;
各接口的发送(Send)和接收(Receive)的版本;
自动汇总生效(Automatic network summarization is in effect);
所路由的网络,172.16.0.0;
路由信息源,即从何处学月来的路由;
治理距离,缺省值为120 。
(2)用ping和trace命令测试网络连通性,尤其是trace命令给出了相应的路径信息 。
(3)我们把R3路由器的S1接口关闭后,使用show ip route指令查看路由表,显示到达172.16.2.0的路由己经变为R1,度量值也变为2.
trace命令的结果也显示了这一变化 。
(4)使用debug ip rip命令可以监测到RIP协议的路由更新发送和接收情况,在此命令后面的若干行中,可以看出RIP协议工作的特点,大致有以下几点:
更新信息缺省情况下向所有参与路由的接口发送;
RIP版木1的更新包是广播包,即目的地址为255.255.255.255;
RIP把整个路由表向相邻路由器发送;
当前所有接口发送和接收的RIP更新包的版本均为1 。
(5)最后应关闭debug进程 。

推荐阅读