被动接口与单播更新

1.实验目的
通过本实验可以掌握:
(1)被动接口的含义、配置和应用场合
(2)单播更新的应用场合和配置
2.拓扑结构
实验拓扑如图 4-2 所示。
Highslide

由于以太口 lo1 和lo2连接主机,不需要向这些接口发送路由更新,所以可以考虑将
路由器的该接口设置为被动接口。
3.实验步骤
(1)步骤 1:配置路由器 R1
R1(config)#router rip
R1(config-router)#version 1
R1(config-router)#network 10.0.0.0
R1(config-router)#network 172.16.0.0
R1(config-router)#network 192.168.1.0
R1(config-router)#passive-interface lo1
R1(config-router)#passive-interface lo2
(2)步骤 2:配置路由器 R2
R2(config)#router rip
R2(config-router)#version 1
R2(config-router)#network 192.168.1.0
R2(config-router)#network 2.0.0.0
4.实验调试
R1#debug ip rip
R1#clear ip route *
[color=#8B0000]Dec 28 17:39:15.515: RIP: sending v1 update to 255.255.255.255 via Serial1/1 (19
2.168.1.1)
[/color]Dec 28 17:39:15.519: RIP: build update entries
Dec 28 17:39:15.519:    network 10.0.0.0 metric 1
Dec 28 17:39:15.523:    network 172.16.0.0 metric 1
R1#
Dec 28 17:39:22.095: RIP: received v1 update from 192.168.1.2 on Serial1/1
Dec 28 17:39:22.095:      2.0.0.0 in 1 hops
Dec 28 17:39:22.979: RIP: received v1 request from 192.168.1.2 on Serial1/1 Dec 28 17:39:22.983: RIP: sending v1 update to 192.168.1.2 via Serial1/1 (192.16
8.1.1)
Dec 28 17:39:22.983: RIP: build update entries
Dec 28 17:39:22.987:    network 10.0.0.0 metric 1
Dec 28 17:39:22.987:    network 172.16.0.0 metric 1
Dec 28 17:39:22.991: RIP: received v1 request from 192.168.1.2 on Serial1/1
Dec 28 17:39:22.991: RIP: sending v1 update to 192.168.1.2 via Serial1/1 (192.16
8.1.1)
Dec 28 17:39:22.999: RIP: build update entries
R1#
Dec 28 17:39:23.003:    network 10.0.0.0 metric 1
Dec 28 17:39:23.003:    network 172.16.0.0 metric 1
Dec 28 17:39:23.011: RIP: received v1 request from 192.168.1.2 on Serial1/1
Dec 28 17:39:23.015: RIP: sending v1 update to 192.168.1.2 via Serial1/1 (192.16
8.1.1)
Dec 28 17:39:23.015: RIP: build update entries
Dec 28 17:39:23.019:    network 10.0.0.0 metric 1
Dec 28 17:39:23.027:    network 172.16.0.0 metric 1
R1#
Dec 28 17:39:25.023: RIP: received v1 update from 192.168.1.2 on Serial1/1
Dec 28 17:39:25.023:      2.0.0.0 in 1 hops

从以上输出可以看出,路由器 R1 确实不向被动接口 lo1 和lo2 发送路由更新。 都是发向Serial1/1

【技术要点】
被动接口只能接收路由更新,不能以广播或组播方式发送更新,但是可以以单播的方式
发送更新,配置单播更新的命令如下:
R1(config-router)#neighbor A.B.C.D
【实例】
如图 4-3 所示,路由器 R1 只想把路由更新送到路由器 R3 上,由于 RIPv1路由协议采用
广播更新, 默认情况下, 路由更新将发送给以太网上任何一个设备, 为了防止这种情况发生,
把路由器 R1的 g0/0 配置成被动接口,然而路由器 R1 还想把路由更新发送给 R3,这时候必
须采用单播更新,为指定的相邻路由器 R3 发送路由更新。路由器 R1 具体的配置如下:
R1(config)#router rip
R1(config-router)#passive-interface fa0/0
R1(config-router)#neighbor 172.16.1.3
Highslide 

你可能感兴趣的:(职场,休闲,单播)