实验二十二、RIP 协议环路避免的几种方法实验配置

实验二十二、RIP 协议环路避免的几种方法实验配置

一、 实验目的

1. 通过实验体会RIP 存在的路由自环的问题

2. 掌握开启和关闭水平分割的配置

二、 应用环境

1. 实验环境下进行,实际工作中不需要

三、 实验设备

1. DCR-1751 两台

2. CR-V35FC 一条

3. CR-V35MT 一条

四、 实验拓扑

clip_image002

五、 实验要求

配置表

ROUTER-A ROUTER-B

S1/1 (DCE ) 192.168.1.1/24 S1/0 (DTE) 192.168.1.2/24

F0/0 192.168.0.1 F0/0 192.169.2.1/24

六、 实验步骤

第一步:按照实验八配置好RIP 协议,并能查看路由表

A 的路由表

Router-A#sh ip route

Codes: C - connected, S - static, R - RIP, B - BGP, BC - BGP connected

D - DEIGRP, DEX - external DEIGRP, O - OSPF, OIA - OSPF inter area ON1 - OSPF NSSA external type 1, ON2 - OSPF NSSA external type 2

OE1 - OSPF external type 1, OE2 - OSPF external type 2

DHCP - DHCP type

VRF ID: 0

C 192.168.0.0/24 is directly connected, FastEthernet0/0

C 192.168.1.0/24 is directly connected, Serial1/1

R 192.168.2.0/24 [120,16] via 192.168.1.2(on Serial1/1)

B 的路由表

Router-B#sh ip route

Codes: C - connected, S - static, R - RIP, B - BGP, BC - BGP connected

D - DEIGRP, DEX - external DEIGRP, O - OSPF, OIA - OSPF inter area

ON1 - OSPF NSSA external type 1, ON2 - OSPF NSSA external type 2

OE1 - OSPF external type 1, OE2 - OSPF external type 2

DHCP - DHCP type

VRF ID: 0

R 192.168.0.0/24 [120,1] via 192.168.1.1(on Serial1/0)

C 192.168.1.0/24 is directly connected, Serial1/0

C 192.168.2.0/24 is directly connected, FastEthernet0/0

第二步:观察水平分割的现象

Router-A#debug ip rip protocol !观察RIP 协议过程

RIP protocol debugging is on

Router-A#2004-1-1 02:25:43 RIP: send to 224.0.0.9 via FastEthernet0/0

2004-1-1 02:25:43 vers 2, CMD_RESPONSE, length 44

2004-1-1 02:25:43 192.168.1.0/24 via 0.0.0.0 metric 1

2004-1-1 02:25:43 192.168.2.0/24 via 0.0.0.0 metric 2

2004-1-1 02:25:43 RIP: send to 224.0.0.9 via Serial1/1

2004-1-1 02:25:43 vers 2, CMD_RESPONSE, length 44

2004-1-1 02:25:43 192.168.0.0/24 via 0.0.0.0 metric 1

!注意到水平分割的作用,A 并不发送 192.168.2.0 这条路由

2004-1-1 02:25:45 RIP: send to 224.0.0.9 via FastEthernet0/0

2004-1-1 02:25:45 vers 2, CMD_RESPONSE, length 44

2004-1-1 02:25:45 192.168.1.0/24 via 0.0.0.0 metric 1

2004-1-1 02:25:45 192.168.2.0/24 via 0.0.0.0 metric 16

2004-1-1 02:25:45 RIP: send to 224.0.0.9 via Serial1/1

2004-1-1 02:25:45 vers 2, CMD_RESPONSE, length 44

2004-1-1 02:25:45 192.168.0.0/24 via 0.0.0.0 metric 1

Router-A#no debug all !一定要记得关闭 debug第三步:关闭水平分割

Router-A#conf

Router-A_config#interface s1/1 !进入与B 相连的接口

Router-A_config_s1/1#no ip rip split-horizon !关闭水平分割

第四步:再次观察RIP 工作过程

Router-A#debug ip rip protocol

RIP protocol debugging is on

Router-A#2004-1-1 02:26:29 RIP: send to 224.0.0.9 via FastEthernet0/0

2004-1-1 02:26:29 vers 2, CMD_RESPONSE, length 44

2004-1-1 02:26:29 192.168.1.0/24 via 0.0.0.0 metric 1

2004-1-1 02:26:29 192.168.2.0/24 via 0.0.0.0 metric 16

2004-1-1 02:26:29 RIP: send to 224.0.0.9 via Serial1/1

2004-1-1 02:26:29 vers 2, CMD_RESPONSE, length 84

2004-1-1 02:26:29 192.168.0.0/24 via 0.0.0.0 metric 1

2004-1-1 02:26:29 192.168.1.0/24 via 0.0.0.0 metric 1

2004-1-1 02:26:29 192.168.2.0/24 via 0.0.0.0 metric 16

!注意到发送的路由中包括192.168.2.0,但由于自环的原因,跳数为16 (不可达)

2004-1-1 02:26:31 RIP: send to 224.0.0.9 via FastEthernet0/0

2004-1-1 02:26:31 vers 2, CMD_RESPONSE, length 44

2004-1-1 02:26:31 192.168.1.0/24 via 0.0.0.0 metric 1

2004-1-1 02:26:31 192.168.2.0/24 via 0.0.0.0 metric 16

2004-1-1 02:26:31 RIP: send to 224.0.0.9 via Serial1/1

2004-1-1 02:26:31 vers 2, CMD_RESPONSE, length 84

Router-A#no debug all !一定要记得关闭 debug

第五步:查看路由表

Router-A#sh ip route

Codes: C - connected, S - static, R - RIP, B - BGP, BC - BGP connected

D - DEIGRP, DEX - external DEIGRP, O - OSPF, OIA - OSPF inter area

ON1 - OSPF NSSA external type 1, ON2 - OSPF NSSA external type 2

OE1 - OSPF external type 1, OE2 - OSPF external type 2

DHCP - DHCP type

VRF ID: 0

C 192.168.0.0/24 is directly connected, FastEthernet0/0

C 192.168.1.0/24 is directly connected, Serial1/1

!已经没有了RIP 学习到的路由

你可能感兴趣的:(协议,休闲,实验,rip,环路)