在同一网络中混合使用RIPV1和RIPV2

       RIP动态路由协议是距离矢量路由协议,在动态学习路由时,采用跳数作为度量值,最大跳数为15,因此在应用RIP协议的网络中,最多允许16台路由器,由此可见,RIP协议只能用在小型网络中。
RIP协议分为RIPV1和RIPV2,RIPV2是RIPV1的升级版本,
RIPV1和RIPV2的不同点:
      RIPV1                                                                   RIPV2
有类路由协议                                                       无类路由协议
不支持VLSM(可变长子网掩码)                   支持VLSM(可变长子网掩码)
不支持不连续子网                                                 支持不连续子网
广播地址:255.255.255.255                                组播地址:224.0.0.9
在网络中,有的路由器配置RIPV1动态路由协议,还有的配置RIPV2动态路由协议,如果不想把RIPV1升级为RIPV2,我们就用RIPV2和RIPV2兼容的方式保证网络的正常通讯,
实验模拟环境:三台路由器(3640)网络拓扑及IP分配如图
在同一网络中混合使用RIPV1和RIPV2_第1张图片
一、配置路由器1
1、基本IP配置 略
2、配置RIPV1路由协议
r1(config)#router rip
r1(config-router)#network 192.168.1.0
r1(config-router)#network 172.16.1.0
二、配置路由器3
1、 基本IP配置 略
2、 配置RIPV1路由协议
r3(config)#router rip
r3(config-router)#network 192.168.2.
r3(config-router)#network 172.16.2.0
三、配置路由器2
1、 基本IP配置 略
2、 配置RIPV2协议
r2(config)#router rip
r2(config-router)#version 2
r2(config-router)#network 172.16.1.0
r2(config-router)#network 172.16.2.0
3、 设置RIPV1和RIPV2兼容
r2(config)#interface s0/0
r2(config-if)#ip rip send version 1
r2(config-if)#ip rip receive version 1
r2(config-if)#int s0/1
r2(config-if)#ip rip send version 1
r2(config-if)#ip rip receive version 1
四、验证:
1、 在r3上查看路由表
r3#show ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, 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
172.16.0.0/24 is subnetted, 2 subnets
R 172.16.1.0 [120/1] via 172.16.2.1, 00:00:03, Serial0/0
C 172.16.2.0 is directly connected, Serial0/0
R 192.168.1.0/24 [120/2] via 172.16.2.1, 00:00:03, Serial0/0
C 192.168.2.0/24 is directly connected, Loopback0
2、 在r1上查看路由表
r1#show ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, 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
172.16.0.0/24 is subnetted, 2 subnets
C 172.16.1.0 is directly connected, Serial0/0
R 172.16.2.0 [120/1] via 172.16.1.2, 00:00:22, Serial0/0
C 192.168.1.0/24 is directly connected, Loopback0
R 192.168.2.0/24 [120/2] via 172.16.1.2, 00:00:22, Serial0/0
使用PING命令验证
r3#ping 192.168.1.1 source 192.168.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 360/399/432 ms

你可能感兴趣的:(网络,职场,休闲)