ROS软路由论坛 ROSABC.com 网络方案网络工程交流

 找回密码
 会员注册

QQ登录

只需一步,快速开始

实战:RIP和EIGRP路由再发布的设置步骤

2014-3-14 16:41| 发布者: admin| 查看: 446| 评论: 0

摘要: 不同的动态路由协议之间需要交换路由表,也需要进行路由再发布。 打开随书光盘中第6章练习07 RIP和EIGRP路由再发布.pkt,网络拓扑如图6-23所示。网络中的路由器和计算机已经按照图示的地址配置完成。Router0和Rout ...

不同的动态路由协议之间需要交换路由表,也需要进行路由再发布。

打开随书光盘中第6章练习“07 RIP和EIGRP路由再发布.pkt”,网络拓扑如图6-23所示。网络中的路由器和计算机已经按照图示的地址配置完成。Router0和Router1运行了RIPv2,并且关闭了自动汇总,Router1和Router2运行了EIGRP协议。

你需要配置Router1将EIGRP协议学到的路由通过RIP协议通告给Router0;配置Router1将RIPv2学到的路由通过EIGRP协议通告给Router2。

▲图6-23 RIP和EIGRP路由再发布的网络拓扑

操作步骤如下。

(1)在Router1上运行show ip route命令查看路由表。

Router1#show ip route

Gateway of last resort is not set

10.0.0.0/30 is subnetted, 2 subnets

C 10.0.0.0 is directly connected, Serial3/0

C 10.0.0.4 is directly connected, Serial2/0

172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks

R 172.16.0.0/24 [120/1] via 10.0.0.1, 00:00:26, Serial3/0

R 172.16.1.0/24 [120/1] via 10.0.0.1, 00:00:26, Serial3/0

R 172.16.2.0/24 [120/1] via 10.0.0.1, 00:00:26, Serial3/0

D 192.168.0.0/24 [90/20514560] via 10.0.0.6, 00:35:10, Serial2/0

可以看到在Router1上的路由表中包括了通过RIP协议学到的路由和通过EIGRP协议学到的路由。

(2)在Router0上查看路由表。

Router0#show ip route

Gateway of last resort is not set

10.0.0.0/30 is subnetted, 2 subnets

C 10.0.0.0 is directly connected, Serial2/0

R 10.0.0.4 [120/1] via 10.0.0.2, 00:00:14, Serial2/0

172.16.0.0/24 is subnetted, 3 subnets

C 172.16.0.0 is directly connected, FastEthernet0/0

C 172.16.1.0 is directly connected, FastEthernet1/0

C 172.16.2.0 is directly connected, FastEthernet6/0

可以看到Router1没有将其通过EIGRP学到的路由通过RIP协议通告给Router0。

(3)在Router2上查看路由表。

同样可以看到Router1没有将其通过RIP学到的路由通过EIGRP协议通告给Router2。

(4)在Router1上配置将EIGRP发布到RIP。

Router1#config t

Router1(config)#router rip

Router1(config-router)#redistribute eigrp 10 metric ?

<0-16> Default metric

transparent Transparently redistribute metric

Router1(config-router)#redistribute eigrp 10 metric 3

最后一条命令将EIGRP协议学到的路由度量值转化为RIP协议的度量值3。

(5)在Router1上配置将RIP发布到EIGRP。

Router1(config)#router eigrp 10

Router1(config-router)#redistribute rip metric 10000 100 255 1 1500

最后一条命令是将RIP学到的路由度量值转化为EIGRP的度量值。其中:

10000:是带宽,单位是kb/s;

100:是延迟,单位是10us;

255:是可靠性,值可以是0~255,255是100%可靠;

1:是负载,值可以是1~255,255是100%负载,即网络将要堵塞;

1500:是最大传输单元(MTU),单位为8比特字节。

(6)在Router0上查看路由表。

Router0#show ip route

Gateway of last resort is not set

10.0.0.0/30 is subnetted, 2 subnets

C 10.0.0.0 is directly connected, Serial2/0

R 10.0.0.4 [120/1] via 10.0.0.2, 00:00:04, Serial2/0

172.16.0.0/24 is subnetted, 3 subnets

C 172.16.0.0 is directly connected, FastEthernet0/0

C 172.16.1.0 is directly connected, FastEthernet1/0

C 172.16.2.0 is directly connected, FastEthernet6/0

R 192.168.0.0/24 [120/3] via 10.0.0.2, 00:12:34, Serial2/0

--学到了再发布的路由

(7)在Router2上查看路由表。

Router2#show ip route

Gateway of last resort is not set

10.0.0.0/8 is variably subnetted, 3 subnets, 2 masks

D 10.0.0.0/8 is a summary, 01:04:04, Null0

D 10.0.0.0/30 [90/21024000] via 10.0.0.5, 01:04:04, Serial3/0

C 10.0.0.4/30 is directly connected, Serial3/0

172.16.0.0/24 is subnetted, 3 subnets

D EX 172.16.0.0 [170/20537600] via 10.0.0.5, 00:07:39, Serial3/0

--再发布的路由

D EX 172.16.1.0 [170/20537600] via 10.0.0.5, 00:07:39, Serial3/0

--再发布的路由

D EX 172.16.2.0 [170/20537600] via 10.0.0.5, 00:07:39, Serial3/0

--再发布的路由

C 192.168.0.0/24 is directly connected, FastEthernet0/0

可以看到D EX开头的路由是EIGRP的外部路由,也就是RIP发布到EIGRP的路由,管理距离是170。

(8)在PC0 上ping PC2,测试网络是否通。

PC>ping 192.168.0.2

(9)在Router1上取消再发布。

Router1(config)#router eigrp 10

Router1(config-router)#no redistribute rip --取消EIGRP到RIP的发布

Router1(config)#router rip

Router1(config-router)#no redistribute eigrp 10 --取消RIP到EIGRP的发布

不良信息举报Q:2000617

软路由

不良信息举报Q:2000617|Archiver|ROS软路由论坛 ROSABC.com 网络方案网络工程交流

GMT+8, 2024-6-2 15:13 , Processed in 0.167482 second(s), 15 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

返回顶部