玩转华为ENSP模拟器系列 | 配置动态BFD检测LDP LSP示例
Posted COCOgsta
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了玩转华为ENSP模拟器系列 | 配置动态BFD检测LDP LSP示例相关的知识,希望对你有一定的参考价值。
素材来源:华为路由器配置指南
一边学习一边整理试验笔记,并与大家分享,侵权即删,谢谢支持!
附上汇总贴:玩转华为ENSP模拟器系列 | 合集_COCOgsta的博客-CSDN博客_ensp实验大全
目标
介绍配置动态BFD检测LDP LSP的配置过程,包括在各设备以及各接口使能MPLS、MPLS LDP,以及在源端和宿端上使能BFD能力。
组网需求
MPLS LDP越来越多的应用在运营商的网络中,运营商对MPLS LDP网路可靠性要求也越来越高,BFD for LDP能够为LDP LSP提供快速的检测机制,当网络发生故障时,BFD能够被快速感知故障同时触发LSP流量进行切换。BFD for LDP常和LDP FRR技术联用。
如图1所示,节点PE1、P1、P2和PE2属于同一MPLS域,PE1和PE2之间创建主备LDP LSP,要求使用动态BFD检测LDP LSP的连通性。
配置思路
- 按照图1所示配置各LSR上的接口IP地址。
- 配置OSPF协议通告各个接口的IP地址,使得各设备间能够互通。调整接口的Cost值,使PE1–P1–PE2成为主路径,PE1–P2–PE2成为备份路径。
- 配置LDP LSP,各节点针对所有路由触发建立LSP。
- 配置LDP Auto FRR,使得PE1和PE2之间生成备份LSP。
- 配置动态BFD for LDP,通过FEC列表触发建立BFD会话。
操作步骤
- 配置各接口的IP地址
根据图1配置接口IP地址,并在节点上创建Loopback接口。具体配置过程请参见配置文件。
- 配置OSPF
在各个节点上配置OSPF,使各设备间网络能互通。具体配置过程请参见配置文件。
- 配置LDP LSP
在各个节点上配置MPLS LDP,触发LDP针对所有路由建立LSP。具体配置过程请参见配置文件。
- 配置LDP Auto FRR
在PE1上使能OSPF FRR以及LDP Auto FRR。
PE1:
ospf 1
frr
loop-free-alternate
mpls ldp
auto-frr lsp-trigger all
在PE2上使能OSPF FRR以及LDP Auto FRR。
PE2:
ospf 1
frr
loop-free-alternate
mpls ldp
auto-frr lsp-trigger all
- 配置动态BFD会话检测LDP LSP
在PE1上使能BFD,指定动态触发BFD会话的FEC列表,配置主机路由触发策略,并调整BFD检测参数。
PE1:
bfd
mpls-passive
fec-list 11
fec-node 4.4.4.4
mpls
mpls bfd enable
mpls bfd-trigger fec-list 11
mpls bfd min-tx-interval 100 min-rx-interval 600 detect-multiplier 4
在PE2上使能BFD,指定动态触发BFD会话的FEC列表,配置主机路由触发策略,并调整BFD检测参数。
PE2:
bfd
mpls-passive
fec-list 12
fec-node 1.1.1.1
mpls
mpls bfd enable
mpls bfd-trigger fec-list 12
mpls bfd min-tx-interval 100 min-rx-interval 600 detect-multiplier 4
- 检查配置结果
执行display bfd session all verbose命令查看动态创建的BFD会话状态。
[~PE1-mpls]dis bfd session all verbose
(w): State in WTR
(*): State is invalid
--------------------------------------------------------------------------------
State : Up Name : dyn_16387
--------------------------------------------------------------------------------
Local Discriminator : 16387 Remote Discriminator : 16391
Session Detect Mode : Asynchronous Mode Without Echo Function
BFD Bind Type : LDP_LSP
Bind Session Type : Dynamic
Bind Peer IP Address : 4.4.4.4
NextHop Ip Address : 10.1.2.2
Bind Interface : Ethernet1/0/1
Tunnel ID : -
FSM Board Id : 1 TOS-EXP : 7
Min Tx Interval (ms) : 100 Min Rx Interval (ms) : 600
Actual Tx Interval (ms): 100 Actual Rx Interval (ms): 600
Local Detect Multi : 4 Detect Interval (ms) : 1800
Echo Passive : Disable Acl Number : -
Destination Port : 3784 TTL : 1
Proc Interface Status : Disable Process PST : Enable
WTR Interval (ms) : - Config PST : Enable
Active Multi : 3
Last Local Diagnostic : Neighbor Signaled Session Down(Receive AdminDown)
Bind Application : LDP
Session TX TmrID : - Session Detect TmrID : -
Session Init TmrID : - Session WTR TmrID : -
Session Echo Tx TmrID : -
Session Description : -
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
State : Up Name : dyn_16388
--------------------------------------------------------------------------------
Local Discriminator : 16388 Remote Discriminator : 16392
Session Detect Mode : Asynchronous Mode Without Echo Function
BFD Bind Type : LDP_LSP
Bind Session Type : Dynamic
Bind Peer IP Address : 4.4.4.4
NextHop Ip Address : 10.1.1.2
Bind Interface : Ethernet1/0/0
Tunnel ID : -
FSM Board Id : 1 TOS-EXP : 7
Min Tx Interval (ms) : 100 Min Rx Interval (ms) : 600
Actual Tx Interval (ms): 100 Actual Rx Interval (ms): 600
Local Detect Multi : 4 Detect Interval (ms) : 1800
Echo Passive : Disable Acl Number : -
Destination Port : 3784 TTL : 1
Proc Interface Status : Disable Process PST : Enable
WTR Interval (ms) : - Config PST : Enable
Active Multi : 3
Last Local Diagnostic : Neighbor Signaled Session Down(Receive AdminDown)
Bind Application : LDP
Session TX TmrID : - Session Detect TmrID : -
Session Init TmrID : - Session WTR TmrID : -
Session Echo Tx TmrID : -
Session Description : -
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
(Multi Hop) State : Up Name : dyn_16389
--------------------------------------------------------------------------------
Local Discriminator : 16389 Remote Discriminator : 16393
Session Detect Mode : Asynchronous Mode Without Echo Function
BFD Bind Type : Peer IP Address
Bind Session Type : Entire_Dynamic
Bind Peer IP Address : 4.4.4.4
Bind Interface : -
Track Interface : -
Bind Source IP Address : 1.1.1.1
FSM Board Id : 1 TOS-EXP : 7
Min Tx Interval (ms) : 3 Min Rx Interval (ms) : 3
Actual Tx Interval (ms): 600 Actual Rx Interval (ms): 100
Local Detect Multi : 3 Detect Interval (ms) : 400
Echo Passive : Disable Acl Number : -
Destination Port : 4784 TTL : 253
Proc Interface Status : Disable Process PST : Disable
WTR Interval (ms) : - Config PST : Disable
Active Multi : 4
Last Local Diagnostic : No Diagnostic
Bind Application : No Application Bind
Session TX TmrID : - Session Detect TmrID : -
Session Init TmrID : - Session WTR TmrID : -
Session Echo Tx TmrID : -
Session Description : -
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
(Multi Hop) State : Up Name : dyn_16390
--------------------------------------------------------------------------------
Local Discriminator : 16390 Remote Discriminator : 16394
Session Detect Mode : Asynchronous Mode Without Echo Function
BFD Bind Type : Peer IP Address
Bind Session Type : Entire_Dynamic
Bind Peer IP Address : 4.4.4.4
Bind Interface : -
Track Interface : -
Bind Source IP Address : 1.1.1.1
FSM Board Id : 1 TOS-EXP : 7
Min Tx Interval (ms) : 3 Min Rx Interval (ms) : 3
Actual Tx Interval (ms): 600 Actual Rx Interval (ms): 100
Local Detect Multi : 3 Detect Interval (ms) : 400
Echo Passive : Disable Acl Number : -
Destination Port : 4784 TTL : 253
Proc Interface Status : Disable Process PST : Disable
WTR Interval (ms) : - Config PST : Disable
Active Multi : 4
Last Local Diagnostic : No Diagnostic
Bind Application : No Application Bind
Session TX TmrID : - Session Detect TmrID : -
Session Init TmrID : - Session WTR TmrID : -
Session Echo Tx TmrID : -
Session Description : -
--------------------------------------------------------------------------------
Total UP/DOWN Session Number : 4/0
[~PE1-mpls]
查看PE2上的被动创建的BFD会话状态,其中BFD Bind Type字段的值为“Peer IP Address”,说明PE2发送的BFD报文是通过IP路由传输的。
[~PE2-mpls]dis bfd session passive-dynamic verbose
(w): State in WTR
(*): State is invalid
--------------------------------------------------------------------------------
(Multi Hop) State : Up Name : dyn_16391
--------------------------------------------------------------------------------
Local Discriminator : 16391 Remote Discriminator : 16387
Session Detect Mode : Asynchronous Mode Without Echo Function
BFD Bind Type : Peer IP Address
Bind Session Type : Entire_Dynamic
Bind Peer IP Address : 1.1.1.1
Bind Interface : -
Track Interface : -
Bind Source IP Address : 4.4.4.4
FSM Board Id : 1 TOS-EXP : 7
Min Tx Interval (ms) : 3 Min Rx Interval (ms) : 3
Actual Tx Interval (ms): 600 Actual Rx Interval (ms): 100
Local Detect Multi : 3 Detect Interval (ms) : 400
Echo Passive : Disable Acl Number : -
Destination Port : 4784 TTL : 253
Proc Interface Status : Disable Process PST : Disable
WTR Interval (ms) : - Config PST : Disable
Active Multi : 4
Last Local Diagnostic : No Diagnostic
Bind Application : No Application Bind
Session TX TmrID : - Session Detect TmrID : -
Session Init TmrID : - Session WTR TmrID : -
Session Echo Tx TmrID : -
Session Description : -
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
(Multi Hop) State : Up Name : dyn_16392
--------------------------------------------------------------------------------
Local Discriminator : 16392 Remote Discriminator : 16388
Session Detect Mode : Asynchronous Mode Without Echo Function
BFD Bind Type : Peer IP Address
Bind Session Type : Entire_Dynamic
Bind Peer IP Address : 1.1.1.1
Bind Interface : -
Track Interface : -
Bind Source IP Address : 4.4.4.4
FSM Board Id : 1 TOS-EXP : 7
Min Tx Interval (ms) : 3 Min Rx Interval (ms) : 3
Actual Tx Interval (ms): 600 Actual Rx Interval (ms): 100
Local Detect Multi : 3 Detect Interval (ms) : 400
Echo Passive : Disable Acl Number : -
Destination Port : 4784 TTL : 253
Proc Interface Status : Disable Process PST : Disable
WTR Interval (ms) : - Config PST : Disable
Active Multi : 4
Last Local Diagnostic : No Diagnostic
Bind Application : No Application Bind
Session TX TmrID : - Session Detect TmrID : -
Session Init TmrID : - Session WTR TmrID : -
Session Echo Tx TmrID : -
Session Description : -
--------------------------------------------------------------------------------
Total UP/DOWN Session Number : 2/0
[~PE2-mpls]
PE1->PE2,走MPLS标签
PE2->PE1,走IP路由
以上是关于玩转华为ENSP模拟器系列 | 配置动态BFD检测LDP LSP示例的主要内容,如果未能解决你的问题,请参考以下文章
玩转华为ENSP模拟器系列 | 配置静态BFD检测三层IP链路
玩转华为ENSP模拟器系列 | 配置静态BFD检测三层IP链路
玩转华为ENSP模拟器系列 | 配置静态BFD检测VPWS PW示例
玩转华为ENSP模拟器系列 | 配置动态BFD for IS-IS特性示例