| 这次实验,目的是为了配置OSPF与EIGRP的路由再发布,共包括了五个步骤,下面给你一一道来,并且附带上所有的配置命令行。 环境:三台路由器串口相连,接口配置如图。 要求:1.配置EIGRP和关闭自动路由汇总。 2.在R1上配置LOOP口的EIGRP手工路由汇总。 3.在R2和R3配置Ospf接口验证。 4.在ASBR(R2)上做eigrp和ospf双向再发布。 5.在R3上将所有loopback口再发布到ospf中,但loopback2不能被R2、R3 学到,不允许使用network命令。 6.练习本课所有show命令。 步骤一:配置三个路由器接口使其连通。 R1的配置 R1(config)# interface Loopback0 R1(config-if)#ip address 172.168.1.1 255.255.255.0 R1(config)# interface Loopback1 R1(config-if)#ip address 172.168.2.1 255.255.255.0 R1(config)#interface Loopback2 R1(config-if)#ip address 172.168.3.1 255.255.255.0 R1(config)# interface s0 R1(config-if)# ip address 10.1.1.1 255.255.255.0 R1(config-if)#clock rate 64000 R1(config-if)#no shutdown R2的配置 R2(config)#interface s0 R2(config-if)#ip address 20.1.1.1 255.255.255.0 R2(config-if)#no shutdown R2(config)#interface s1 R2(config-if)# ip address 10.1.1.1 255.255.255.0 R2(config-if)#no shutdown R3的配置 R3(config)# interface Loopback0 R3(config-if)#ip address 192.168.1.1 255.255.255.0 R3(config)# interface Loopback1 R3(config-if)#ip address 192.168.2.1 255.255.255.0 R3(config)#interface Loopback2 R3(config-if)#ip address 192.168.3.1 255.255.255.0 R3(config)# interface s1 R3(config-if)# ip address 20.1.1.2 255.255.255.0 R3(config-if)#clock rate 64000 R3(config-if)#no shutdown 步骤二: 配置Eigrp ,Ospf R1 的配置 R1(config)# router eigrp 100 à启用EIGRP R1(config-router)# network 10.1.1.0 0.0.0.255 à发布相应接口 R1(config-router)#network 172.168.1.0 0.0.0.255 R1(config-router)#network 172.168.2.0 0.0.0.255 R1(config-router)#network 172.168.3.0 0.0.0.255 R1(config-router)# no auto-summary à关闭自动汇总 R2 的配置 R2(config)# router eigrp 100 R2(config-router)# network 10.1.1.0 0.0.0.255 R2(config-router)# no auto-summary R2(config)# router ospf 10 à在R2 上即启用EIGRP并且启用OSPF R2(config-router)# network 20.1.1.0 0.0.0.255 area 0 R3 的配置 R3(config)# router ospf 10 R3(config-router)# network 20.1.1.0 0.0.0.255 area 0 步骤三:配置EIGRP手工路由汇总和Ospf接口验证 R1 的配置 R1(config)# interface s0 R1(config-if)# ip summary-address eigrp 100 172.168.0.0 255.255.252.0 à手工汇总 R2 的配置 R2(config)# interface s0 R2(config-if)# ip ospf authentication message-digest à启用接口验证 R2(config-if)# ip ospf message-digest-key 1 md5 cisco R3 的配置 R3(config)# interface s1 R3(config-if)# ip ospf authentication message-digest à启用接口认证 R3(config-if)# ip ospf message-digest-key 1 md5 cisco 步骤四:在R2,R3上做路由再发布并控制loopback2不能被R1,R2学到 R2 的配置 R2(config)# router eigrp 100 R2(config-router)# redistribute ospf 10 metric 10000 100 255 1 1500à将ospf重分发进eigrp R2(config)# router ospf 10 R2(config-router)# redistribute eigrp 100 subnets à将eigrp路由重分发到ospf R3的配置: R3(config)# access-list 1 permit 192.168.1.0 0.0.0.255 à定义分发条件列表 R3(config)# access-list 1 permit 192.168.2.0 0.0.0.255 R3(config)# access-list 2 permit 192.168.3.0 0.0.0.255 R3(config)# route-map o-e permit 10   à做映射列表允许相应条目 R3 (config-route-map)# match ip address 1 à将列表加载 R3(config)# route-map o-e deny 20 à拒绝相应条目的映射列表 R3 (config-route-map)# match ip address 2 à将列表加载 R3(config)# route-map o-e permit 25 à最后允许其它所有 R3(config)# router ospf 10 R3(config-router)# redistribute connected subnets route-map o-e 步骤五:查看路由表 #sh ip route | 
不良信息举报Q:2000617|Archiver|ROS软路由论坛 ROSABC.com 网络方案网络工程交流
GMT+8, 2025-10-31 20:14 , Processed in 0.029464 second(s), 15 queries .
Powered by Discuz! X3.4
Copyright © 2001-2021, Tencent Cloud.