Skip to main content

 路由器设置 > 新闻资讯 >

EIGRP综合实验2

2013-11-16 01:09 浏览:

EIGRP综合实验2

配置要点

l帧中继交换机以及PVC的配置

l帧中继多点子接口配置

l帧中继点对点子接口配置

lEIGRP基本配置(包括静态邻居的配置)

lNTP配置

lEIGRP认证配置

实验拓扑

171937401.png

配置概述

lFRSW上配置帧中继交换机,PVC的设计如下:

nR41--S1/0--S1/0.12------412------S1/0--FRSW--S1/1------421------S1/0--R42

nR41--S1/0--S1/0.12------415------S1/0--FRSW--S1/3------451------S1/0--R45

nR41--S1/0--S1/0.14------414------S1/0--FRSW--S1/2------441------S1/0--R44

l各站点的IP地址设计如下:

nR41--S1/0--S1/0.12--172.14.12.41/24------172.14.12.42/24--S1/0--R42

n ------172.14.12.45/24--S1/0--R45

nR41--S1/0--S1/0.14--172.14.14.41/24------172.14.14.44/24--S1/0--R44

lEIGRP的基本配置,包括静态邻居的配置;

lNTP的配置:

nR41配置为NTP的服务器;

nR42R45R44配置为NTP的客户端

lR41为中心与其他各个站点(R42R45R44)配置EIGRP认证。

配置步骤

配置帧中继交换机

首先配置帧中继交换机

Router(config)#host FRSW3

FRSW3(config)#frame-relay switching //全局启动帧中继交换

FRSW3(config)#int s 1/0

FRSW3(config-if)#cl ra 128000

FRSW3(config-if)#encap frame-relay ietf

FRSW3(config-if)#frame lmi-type q933a

FRSW3(config-if)#frame intf-type dce

FRSW3(config-if)#frame route 412 int s 1/1 421

FRSW3(config-if)#frame route 415 int s 1/3 451

FRSW3(config-if)#frame route 414 int s 1/2 441

FRSW3(config-if)#no sh

FRSW3(config-if)#int s 1/1

FRSW3(config-if)#clock rate 128000

FRSW3(config-if)#encap frame ietf

FRSW3(config-if)#frame lmi-type q933a

FRSW3(config-if)#frame intf-type dce

FRSW3(config-if)#frame route 421 int s 1/0 412

FRSW3(config-if)#no sh

FRSW3(config-if)#int s 1/3

FRSW3(config-if)#cl ra 128000

FRSW3(config-if)#encap frame ietf

FRSW3(config-if)#frame lmi-type q933a

FRSW3(config-if)#frame intf-type dce

FRSW3(config-if)#frame route 451 int s 1/0 415

FRSW3(config-if)#no sh

FRSW3(config-if)#int s 1/2

FRSW3(config-if)#cl ra 128000

FRSW3(config-if)#encap frame ietf

FRSW3(config-if)#frame lmi-type q933a

FRSW3(config-if)#frame intf-type dce

FRSW3(config-if)#frame route 441 int s 1/0 414

FRSW3(config-if)#no sh

FRSW3(config-if)#^Z

FRSW3#

 

配完之后看看接口

FRSW3#sh ip int br

Interface IP-Address OK? Method Status Protocol

Ethernet0/0 unassigned YES unset administratively down down

Serial0/0 unassigned YES unset administratively down down

Ethernet0/1 unassigned YES unset administratively down down

Serial1/0 unassigned YES unset down down

Serial1/1 unassigned YES unset down down

Serial1/2 unassigned YES unset down down

Serial1/3 unassigned YES unset down down

唉!现在都是Down的!因为站点的路由器都还没有配置呢。

中心和分支站点的配置

中心R41的配置

Router(config)#host R41

R41(config-line)#int e 0/0

R41(config-if)#ip add 192.168.41.1 255.255.255.0

R41(config-if)#no sh

R41(config-if)#int s 1/0

R41(config-if)#encap frame ietf

R41(config-if)#frame lmi-type q933a

R41(config-if)#exit

R41(config)#int s 1/0.12 ?

multipoint Treat as a multipoint link

point-to-point Treat as a point-to-point link

 

R41(config)#int s 1/0.12 multipoint //多点子接口

R41(config-subif)#ip add 172.14.12.41 255.255.255.0

R41(config-subif)#frame map ip 172.14.12.42 412

R41(config-subif)#frame map ip 172.14.12.45 415

R41(config-subif)#no sh

R41(config-subif)#exit

R41(config)#

 

继续点对点子接口的配置

R41(config)#int s 1/0.14 ?

multipoint Treat as a multipoint link

point-to-point Treat as a point-to-point link

 

R41(config)#int s 1/0.14 point-to-point

R41(config-subif)#ip add 172.14.14.41 255.255.255.0

R41(config-subif)#no sh

R41(config-subif)#frame-relay interface-dlci 414

R41(config-fr-dlci)#no sh

R41(config-subif)#^Z

R41#

 

分支站点R42的配置

Router(config)#host R42

R42(config)#int e 0/0

R42(config-if)#ip add 192.168.42.1 255.255.255.0

R42(config-if)#no sh

R42(config-if)#int s 1/0

R42(config-if)#encap frame ietf

R42(config-if)#frame lmi-type q933a

R42(config-if)#ip add 172.14.12.42 255.255.255.0

R42(config-if)#no sh

R42(config-if)#^Z

R42#

 

忙活半天了,这时可以看看接口

R42#sh ip int br

Interface IP-Address OK? Method Status Protocol

Ethernet0/0 192.168.42.1 YES manual up up

Ethernet0/1 unassigned YES unset administratively down down

Serial1/0 172.14.12.42 YES manual up up // UP啦!!!

Serial1/1 unassigned YES unset administratively down down

Serial1/2 unassigned YES unset administratively down down

Serial1/3 unassigned YES unset administratively down down

R42#

 

分支站点R45的配置

Router(config)#host R45

R45(config)#int e 0/0

R45(config-if)#ip add 192.168.45.1 255.255.255.0

R45(config-if)#no sh

R45(config-if)#int s 1/0

R45(config-if)#encap frame ietf

R45(config-if)#frame lmi-type q933a

R45(config-if)#ip add 172.14.12.45 255.255.255.0

R45(config-if)#no sh

R45(config-if)#^Z

 

看看接口

R45#sh ip int brief

Interface IP-Address OK? Method Status Protocol

Ethernet0/0 192.168.45.1 YES manual up up

Ethernet0/1 unassigned YES unset administratively down down

Serial1/0 172.14.12.45 YES manual up up //UP啦!!

Serial1/1 unassigned YES unset administratively down down

Serial1/2 unassigned YES unset administratively down down

Serial1/3 unassigned YES unset administratively down down

R45#

 

分支站点R44的配置

Router(config)#host R44

R44(config)#int e0/0

R44(config-if)#ip add 192.168.44.1 255.255.255.0

R44(config-if)#no sh

R44(config-if)#int s 1/0

R44(config-if)#encap frame ietf

R44(config-if)#frame lmi-type q933a

R44(config-if)#ip add 172.14.14.44 255.255.255.0

R44(config-if)#no sh

R44(config-if)#^Z

 

看看接口

R44#sh ip int br

Interface IP-Address OK? Method Status Protocol

Ethernet0/0 192.168.44.1 YES manual up up

Ethernet0/1 unassigned YES unset administratively down down

Serial1/0 172.14.14.44 YES manual up up //UP啦!!!

Serial1/1 unassigned YES unset administratively down down

Serial1/2 unassigned YES unset administratively down down

Serial1/3 unassigned YES unset administratively down down

R44#

 

 

 

完成中心和分支站点的配置之后,测试PVC之间的连通性,首先在中心站点R41上测试

R41#ping 172.14.12.42 //ping R42

!!!!!

R41#ping 172.14.12.45 //ping R45

!!!!!

R41#ping 172.14.14.44 //ping R44

!!!!!

 

在分支站点上测试

R44#ping 172.14.14.41 //R44R41

!!!!!

R42#ping 172.14.12.41 //R42R41

!!!!!

R42#ping 172.14.12.45 //R42R45

….. //不通!!!

R45#ping 172.14.12.41 //R45R41

!!!!!

R45#ping 172.14.12.42 //R45R42

..... //不通!!!

 

分支站点R45R42上接着配置

R45(config)#int s 1/0

R45(config-if)#frame map ip 172.14.12.42 451

R45(config-if)#^Z

R42(config)#int s 1/0

R42(config-if)#frame map ip 172.14.12.45 421

R42(config-if)#^Z

 

然后再测试

R42#ping 172.14.12.45 //R42R45

!!!!!

R45#ping 172.14.12.42 //R45R42

!!!!!

终于各站点之间,都通啦!!!呵呵,辛苦啦!

EIGRP的配置

各个站点的配置

R41(config)#router eigrp 100

R41(config-router)#no auto-summary

R41(config-router)#net 192.168.41.0

R41(config-router)#net 172.14.12.0 0.0.0.255 //注意

R41(config-router)#passive-interface e 0/0

R41(config-router)#^Z

R42(config)#router eigrp 100

R42(config-router)#pass e 0/0

R42(config-router)#no auto

R42(config-router)#net 192.168.42.0

R42(config-router)#net 172.14.12.0 0.0.0.255

R42(config-router)#^Z

R45(config)#router eigrp 100

R45(config-router)#no auto

R45(config-router)#pass e 0/0

R45(config-router)#net 192.168.45.0

R45(config-router)#net 172.14.12.0 0.0.0.255

R45(config-router)#^Z

R44(config)#router eigrp 100

R44(config-router)#no auto

R44(config-router)#pass e 0/0

R44(config-router)#net 192.168.44.0

R44(config-router)#net 172.14.14.0 0.0.0.255

R44(config-router)#^Z

 

R41上看看路由表

R41#sh ip route

 

Gateway of last resort is not set

 

172.14.0.0/24 is subnetted, 2 subnets

C 172.14.14.0 is directly connected, Serial1/0.14

C 172.14.12.0 is directly connected, Serial1/0.12

C 192.168.41.0/24 is directly connected, Ethernet0/0

R41#

OMG!全是C!!!故障排查吧。

 

R41上看看邻居表

R41#sh ip eigrp nei

IP-EIGRP neighbors for process 100

H Address Interface Hold Uptime SRTT RTO Q Seq

(sec) (ms) Cnt Num

1 172.14.12.45 Se1/0.12 140 00:00:39 1 5000 1 0

0 172.14.12.42 Se1/0.12 168 00:02:00 1 5000 1 0

R41#

有邻居!别着急,到别的路由器上看看在说!

 

R44上看看路由表

R44#sh ip route

 

Gateway of last resort is not set

 

C 192.168.44.0/24 is directly connected, Ethernet0/0

172.14.0.0/24 is subnetted, 1 subnets

C 172.14.14.0 is directly connected, Serial1/0

R44#

OMG!还是C!!!

 

看看邻居表

R44#sh ip eigrp nei

IP-EIGRP neighbors for process 100

R44#

根本就没有邻居!

 

在看看R42的路由表

R42#sh ip route

 

Gateway of last resort is not set

 

C 192.168.42.0/24 is directly connected, Ethernet0/0

172.14.0.0/24 is subnetted, 1 subnets

C 172.14.12.0 is directly connected, Serial1/0

R42#

 

看看R42的邻居

R42#sh ip eigrp nei

IP-EIGRP neighbors for process 100

R42#

也没有邻居!

 

没有邻居,咱就手动建立邻居!

R41(config)#router eigrp 100

R41(config-router)#neighbor 172.14.12.42 serial 1/0.12

R41(config-router)#neighbor 172.14.12.45 serial 1/0.12

R41(config-router)#neighbor 172.14.14.44 serial 1/0.14

R41(config-router)#^Z

R41#

R42(config)#router eigrp 100

R42(config-router)#nei 172.14.12.41 s 1/0

R42(config-router)#nei 172.14.12.45 s 1/0

R42(config-router)#^Z

R45(config)#router eigrp 100

R45(config-router)#neighbor 172.14.12.41 s 1/0

R45(config-router)#neighbor 172.14.12.42 s 1/0

R45(config-router)#^Z

R44(config)#router eigrp 100

R44(config-router)#nei 172.14.14.41 s 1/0

R44(config-router)#^Z

 

配置完静态邻居之后,再到R44上看看邻居表

R44#sh ip eigrp nei

IP-EIGRP neighbors for process 100

R44#

还是没有邻居!一定是哪里错啦!

 

R44上产看运行配置文件

R44#sh run

!

hostname R44

!

no ip domain lookup

!

interface Ethernet0/0

ip address 192.168.44.1 255.255.255.0

half-duplex

!

interface Serial1/0

ip address 172.14.14.44 255.255.255.0

encapsulation frame-relay IETF

serial restart-delay 0

frame-relay lmi-type q933a

!

router eigrp 100

passive-interface Ethernet0/0

network 172.14.14.0 0.0.0.255

network 192.168.44.0

neighbor 172.14.14.41 Serial1/0

no auto-summary

!

没错!

 

在看看R41的运行配置文件

R41#sh run

!

hostname R41

!

no ip domain lookup

!

interface Ethernet0/0

ip address 192.168.41.1 255.255.255.0

half-duplex

!

interface Serial1/0

no ip address

encapsulation frame-relay IETF

serial restart-delay 0

no dce-terminal-timing-enable

frame-relay lmi-type q933a

!

interface Serial1/0.12 multipoint

ip address 172.14.12.41 255.255.255.0

frame-relay map ip 172.14.12.42 412

frame-relay map ip 172.14.12.45 415

!

interface Serial1/0.14 point-to-point

ip address 172.14.14.41 255.255.255.0

frame-relay interface-dlci 414

!

router eigrp 100

passive-interface Ethernet0/0

network 172.14.12.0 0.0.0.255

network 192.168.41.0

no auto-summary

neighbor 172.14.12.45 Serial1/0.12

neighbor 172.14.12.42 Serial1/0.12

!

看出错误了么?这是百密一疏啊!在eigrp 100中没有宣告网络172.14.14.0 0.0.0.255

 

改吧

R41(config)#router eigrp 100

R41(config-router)#net 172.14.14.0 0.0.0.255

 

再看邻居表和路由表

R41#sh ip eigrp nei

IP-EIGRP neighbors for process 100

H Address Interface Hold Uptime SRTT RTO Q Seq

(sec) (ms) Cnt Num

2 172.14.14.44 Se1/0.14 169 00:00:12 30 200 0 2

1 172.14.12.45 Se1/0.12 169 00:03:05 24 200 0 8

0 172.14.12.42 Se1/0.12 169 00:04:01 24 200 0 8

R41#

R41#sh ip route

 

Gateway of last resort is not set

 

D 192.168.44.0/24 [90/2195456] via 172.14.14.44, 00:00:14, Serial1/0.14

D 192.168.45.0/24 [90/2195456] via 172.14.12.45, 00:03:09, Serial1/0.12

D 192.168.42.0/24 [90/2195456] via 172.14.12.42, 00:04:05, Serial1/0.12

172.14.0.0/24 is subnetted, 2 subnets

C 172.14.14.0 is directly connected, Serial1/0.14

C 172.14.12.0 is directly connected, Serial1/0.12

C 192.168.41.0/24 is directly connected, Ethernet0/0

R41#

终于正常啦!

NTP的配置

R41上看看系统时间

R41#sh clock

*09:23:21.363 UTC Thu Aug 18 2011

R41#

时间不对!

 

我们来修改系统时间,还记得学CCNA时候的clock set命令吗?并且把R41配置为NTP服务器。

R41#clock set 20:00:00 22 aug 2011

R41#

R41#sh clock

20:00:05.763 UTC Mon Aug 22 2011

R41#

R41#conf t

R41(config)#ntp master 10

R41(config)#^Z

 

R42上配置NTP客户机

R42#conf t

R42(config)#ntp server 172.14.12.41

R42(config)#^Z

R42#sh clock

*09:25:00.715 UTC Thu Aug 18 2011 //错误的时间

R42#sh clock

*09:25:03.179 UTC Thu Aug 18 2011

R42#sh clock

*09:25:05.707 UTC Thu Aug 18 2011

R42#sh clock

.20:00:58.610 UTC Mon Aug 22 2011 //同步之后的时间

R42#

 

把其他几个站点也配置为NTP客户端

R45(config)#ntp server 172.14.12.41

R45(config)#^Z

R44(config)#ntp server 172.14.14.41

R44(config)#^Z

通过show clock命令来确认时间同步。

EIGRP认证的配置

R44上配置

R44(config)#key chain R44CHAIN //创建密钥环

R44(config-keychain)#key 1 //第一个key

R44(config-keychain-key)#key-string TechNow //密码

R44(config-keychain-key)#send 20:00:00 22 aug 2011 in //发送时间

R44(config-keychain-key)#accept 20:00:00 22 aug 2011 in //接受时间

R44(config-keychain-key)#exit

R44(config-keychain)#exit

R44(config)#int s 1/0 //进入接口

R44(config-if)#ip authentication mode eigrp 100 md5 //认证方式

R44(config-if)#ip authen key-chain eigrp 100 R44CHAIN //启用密钥环

R44(config-if)#^Z

 

配完认证之后,看看邻居表

R44#sh ip eigrp nei

IP-EIGRP neighbors for process 100

R44#

这次邻居没了!

 

再到R41上配置认证

R41(config)#key chain R41CHAIN //创建密钥环

R41(config-keychain)#key 1 //第一个key

R41(config-keychain-key)#key-string TechNow //密码

R41(config-keychain-key)#send 20:00:00 22 aug 2011 in //发送时间

R41(config-keychain-key)#accept 20:00:00 22 aug 2011 in //接受时间

R41(config-keychain-key)#exit

R41(config-keychain)#exit

R41(config)#int s 1/0.14 //进入接口

R41(config-subif)#ip authen mode eigrp 100 md5 //认证方式

R41(config-subif)#ip authentication key eigrp 100 R41CHAIN //启用密钥环

R41(config-subif)#^Z

 

等一会儿,在R41(或者R44)上看看邻居

R41#sh ip eigrp nei

IP-EIGRP neighbors for process 100

H Address Interface Hold Uptime SRTT RTO Q Seq

(sec) (ms) Cnt Num

2 172.14.14.44 Se1/0.14 167 00:00:12 160 960 0 6

1 172.14.12.42 Se1/0.12 167 00:00:47 28 200 0 16

0 172.14.12.45 Se1/0.12 167 00:00:47 28 200 0 16

R41#

 

这次我们试着把密码改成不一样的

R41(config)#key chain R41CHAIN

R41(config-keychain)#key 1

R41(config-keychain-key)#key-string cisco //注意,改了,原来是TechNow

R41(config-keychain-key)#^Z

R41#

 

再看看邻居

R41#sh ip eigrp nei

IP-EIGRP neighbors for process 100

H Address Interface Hold Uptime SRTT RTO Q Seq

(sec) (ms) Cnt Num

1 172.14.12.42 Se1/0.12 178 00:01:50 26 200 0 17

0 172.14.12.45 Se1/0.12 165 00:01:50 27 200 0 17

R41#

果然少了一个!

 

我们再改回来

R41(config)#key chain R41CHAIN

R41(config-keychain)#key 1

R41(config-keychain-key)#key-string TechNow //又改成TechNow

R41(config-keychain-key)#^Z

 

再看看邻居表

R41#sh ip eigrp nei

IP-EIGRP neighbors for process 100

H Address Interface Hold Uptime SRTT RTO Q Seq

(sec) (ms) Cnt Num

2 172.14.14.44 Se1/0.14 179 00:00:00 1 2000 1 0 //又回来了

1 172.14.12.42 Se1/0.12 137 00:04:22 26 200 0 17

0 172.14.12.45 Se1/0.12 139 00:04:22 27 200 0 17

R41#

 

R41R44之间的认证连玩儿带做完成了,现在把R41R42R45之间的认证配完!

R41(config)#int s 1/0.12

R41(config-subif)#ip authentication mode eigrp 100 md5

R41(config-subif)#ip authentication key-chain eigrp 100 R41CHAIN

R41(config-subif)#^Z

R42(config)#key chain R42CHAIN

R42(config-keychain)#key 1

R42(config-keychain-key)#key-string TechNow

R42(config-keychain-key)#send 20:00:00 22 aug 2011 in

R42(config-keychain-key)#accept 20:00:00 22 aug 2011 in

R42(config-keychain-key)#exit

R42(config-keychain)#exit

R42(config)#int s 1/0

R42(config-if)#ip authen mode eigrp 100 md5

R42(config-if)#ip authen key eigrp 100 R42CHAIN

R42(config-if)#^Z

R45(config)#key chain R45CHAIN

R45(config-keychain)#key 1

R45(config-keychain-key)# key-string TechNow

R45(config-keychain-key)#send 20:00:00 22 aug 2011 infinite

R45(config-keychain-key)#accept 20:00:00 22 aug 2011 infinite

R45(config-keychain-key)#exit

R45(config-keychain)#exit

R45(config)#int s 1/0

R45(config-if)#ip authen mode eigrp 100 md5

R45(config-if)#ip authen key eigrp 100 R45CHAIN

R45(config-if)#^Z

 

再看看R45的邻居表

R45#sh ip eigrp nei

IP-EIGRP neighbors for process 100

H Address Interface Hold Uptime SRTT RTO Q Seq

(sec) (ms) Cnt Num

1 172.14.12.42 Se1/0 139 00:00:41 70 420 0 26

0 172.14.12.41 Se1/0 139 00:00:41 42 252 0 45

R45#

邻居关系正常!

 

R45上看看路由表

R45#sh ip route

 

Gateway of last resort is not set

 

D 192.168.44.0/24 [90/2707456] via 172.14.12.41, 00:00:47, Serial1/0

C 192.168.45.0/24 is directly connected, Ethernet0/0

D 192.168.42.0/24 [90/2195456] via 172.14.12.42, 00:00:46, Serial1/0

172.14.0.0/24 is subnetted, 2 subnets

D 172.14.14.0 [90/2681856] via 172.14.12.41, 00:00:47, Serial1/0

C 172.14.12.0 is directly connected, Serial1/0

D 192.168.41.0/24 [90/2195456] via 172.14.12.41, 00:00:47, Serial1/0

R45#

一切正常!

 

怎么着?再玩一次?

R41

R41(config)#key chain R41CHAIN

R41(config-keychain)#key 1

R41(config-keychain-key)#key-string cisco //原来是TechNow

R41(config-keychain-key)#^Z

 

R41上看看邻居

R41#sh ip eigrp nei

IP-EIGRP neighbors for process 100

R41#

邻居没了!

 

R41上再把密码改正确

R41(config)#key chain R41CHAIN

R41(config-keychain)#key 1

R41(config-keychain-key)#key-string TechNow //密码改成正确的了

R41(config-keychain-key)#^Z

 

稍等一会儿,再看看邻居表

R41#sh ip eigrp nei

IP-EIGRP neighbors for process 100

H Address Interface Hold Uptime SRTT RTO Q Seq

(sec) (ms) Cnt Num

2 172.14.14.44 Se1/0.14 179 00:00:02 40 240 0 13

1 172.14.12.42 Se1/0.12 179 00:00:57 831 4986 0 32

0 172.14.12.45 Se1/0.12 179 00:00:57 31 200 0 32

R41#

至此,实验完成!