路由器怎么设置链路检测,路由器开启链路聚合都能怎么用

首页 > 实用技巧 > 作者:YD1662023-11-30 22:35:40

路由器怎么设置链路检测,路由器开启链路聚合都能怎么用(1)

本示例的基本拓扑结构如图所示,现网中有3台路由器通过IS-IS协议实现路由互通,且Router-A和Router-B之间通过一台二层交换机及实现互联。现要求当Router-A与Router-B之间出现链路故障时,能快速检测到。

由于本实例中Router-A和Router-C中间隔了一个Router-B,所以不能建立IS-IS邻居,不能通过IS-IS与BFD的联动检测Router-A到Router-C之间的多跳链路(因为IS-IS还只能建立单跳邻居关系),只能正在Router-A和Router-B之间检测单跳链路。

1) 配置各路由器的接口IP地址

【Router-A上的配置】

interface GigabitEthernet1/0/0

ip address 10.1.1.1 255.255.255.0

#

【Router-B上的配置】

interface GigabitEthernet1/0/0

ip address 10.1.1.2 255.255.255.0

#

interface GigabitEthernet2/0/0

ip address 10.2.1.1 255.255.255.0

#

【Router-C上的配置】

interface GigabitEthernet1/0/0

ip address 10.2.1.2 255.255.255.0

#

2) 配置各路由器的IS-IS基本功能

【Router-A上的配置】

isis 1

is-level level-2

network-entity aa.1111.1111.1111.00

#

interface GigabitEthernet1/0/0

ip address 10.1.1.1 255.255.255.0

isis enable 1

#

【Router-B上的配置】

isis 1

is-level level-2

network-entity aa.2222.2222.2222.00

#

interface GigabitEthernet1/0/0

ip address 10.1.1.2 255.255.255.0

isis enable 1

#

interface GigabitEthernet2/0/0

ip address 10.2.1.1 255.255.255.0

isis enable 1

【Router-C上的配置】

isis 1

is-level level-2

network-entity aa.3333.3333.3333.00

#

interface GigabitEthernet1/0/0

ip address 10.2.1.2 255.255.255.0

isis enable 1

【在RouterA上执行display isis peer命令,即可以看到Router-A和Router-B建立邻居关系】

<Router-A>display isis peer

Peer information for ISIS(1)

System Id Interface Circuit Id State HoldTime Type PRI

-------------------------------------------------------------------------------

2222.2222.2222 GE1/0/0 1111.1111.1111.01 Up 26s L2 64

Total Peer(s): 1

<Router-A>

【在RouterA上执行display isis route命令,即可以看到Router-A和Router-B建立邻居关系】

<Router-A>display isis route

Route information for ISIS(1)

-----------------------------

ISIS(1) Level-2 Forwarding Table

--------------------------------

IPV4 Destination IntCost ExtCost ExitInterface NextHop Flags

---------------------------------------------------------------------------

10.1.1.0/24 10 NULL GE1/0/0 Direct D/-/L/-

10.2.1.0/24 20 NULL GE1/0/0 10.1.1.2 A/-/-/-

Flags: D-Direct, A-Added to URT, L-Advertised in LSPs, S-IGP Shortcut,

U-Up/Down Bit Set

<Router-A>

3) 在Router-A和Router-B上分别配置IS-IS与静态BFD联动,包括创建BFD会话

【Router-A上的配置】

bfd

#

bfd atob bind peer-ip 10.1.1.2 interface GigabitEthernet1/0/0

discriminator local 1

discriminator remote 2

commit

#

interface GigabitEthernet1/0/0

ip address 10.1.1.1 255.255.255.0

isis enable 1

isis bfd static

【Router-B上的配置】

bfd

#

#

bfd btoa bind peer-ip 10.1.1.1 interface GigabitEthernet1/0/0

discriminator local 2

discriminator remote 1

commit

#

interface GigabitEthernet1/0/0

ip address 10.1.1.2 255.255.255.0

isis enable 1

isis bfd static

#

4) 配置验证

l 以上配置后后,通过在Router-A或Router-B上执行display bfd session命令可以看到它们之间的BFD会话的状态为Up。

<Router-A>display bfd session all

---------------------------------------------------------------------------

Local Remote PeerIpAddr State Type InterfaceName

---------------------------------------------------------------------------

1 2 10.1.1.2 Up S_IP_IF GigabitEthernet1/0/0

---------------------------------------------------------------------------

Total UP/DOWN Session Number : 1/0

<Router-A>

在Router-A上打开终端显示信息中心发送的日志信息功能。

<Router-A>terminal logging

Info: Current terminal logging is on.

<Router-A>terminal monitor

Info: Current terminal monitor is on.

<Router-A>

l 对Router-B的G1/0/0接口执行shutdown命令,模拟链路故障。

<Router-A>

May 15 2023 13:08:27-08:00 Router-A %BFD/4/STACHG_TODWN(l)[1]:BFD session changed to Down. (SlotNumber=0, Discriminator=16777216, Diagnostic=DetectDown, Applications=None, ProcessPST=False, BindInterfaceName=GigabitEthernet1/0/0, InterfacePhysicalState=Up, InterfaceProtocolState=Up)

<Router-A>

May 15 2023 13:08:27-08:00 Router-A %ISIS/4/PEER_DOWN_BFDDOWN(l)[2]:ISIS 256 neighbor 2222.2222.2222 was Down on interface GE1/0/0 because the BFD node was down. The Hello packet was received at 13:05:43 last time; the maximum interval for sending Hello packets was 438763520; the local router sent 1980500224 Hello packets and received 419758080 packets; the type of the Hello packet was Lan Level-2.

<Router-A>

May 15 2023 13:08:27-08:00 Router-A %ISIS/4/ADJ_CHANGE_LEVEL(l)[3]:The neighbor of ISIS was changed. (IsisProcessId=256, Neighbor=2222.2222.2222, InterfaceName=GE1/0/0, CurrentState=up, ChangeType=L2_BFD_DOWN, Level=Level-2)

<Router-A>

May 15 2023 13:08:27-08:00 Router-A %ISIS/4/ADJ_CHANGE_LEVEL(l)[4]:The neighbor of ISIS was changed. (IsisProcessId=256, Neighbor=2222.2222.2222, InterfaceName=GE1/0/0, CurrentState=down, ChangeType=L2_HOLDTIMER_EXPIRED, Level=Level-2)

<Router-A>

l 再在Router-A上执行display isis route或display isis peer命令,没有显示任何信息,表明Router-A与Router-B之间的IS-IS邻居关系已经拆除。

<Router-A>display isis peer

<Router-A>

栏目热文

文档排行

本站推荐

Copyright © 2018 - 2021 www.yd166.com., All Rights Reserved.