示例:在 VPLS 网络中配置由于 MAC 移动而导致的环路防御
MAC 移动 VPLS 网络中的环路预防概述
从 Junos OS 14.2 版开始,您可以对路由器进行配置,以防止出现 VPLS 网络中的环路。在虚拟专用 LAN 服务 (VPLS) 部署中,如果之前学习的媒体访问控制 (MAC) 地址出现在不同的物理接口上,例如本地接口(千兆以太网接口)或标签交换接口 (LSI)),或者同一物理接口的不同单元中,如果此行为频繁发生,则被视为 MAC 移动。
您可以将路由器配置为根据以下参数报告 MAC 地址移动:
MAC 地址移动发生的次数
发生 MAC 地址移动的指定时间段
网络配置错误可能会迫使流量进入永无止境的循环路径或环路。VPLS 网络中的这些环路会导致不同接口之间的频繁 MAC 移动,这可用于通过在网络中禁用此类接口来纠正问题。以下两种方法可用于禁用导致环路的接口:
基本学习接口(基本IFL)方法算法 — 这是用于禁用环路接口的主要方法。对于路由实例中的每个 MAC,将维护基本接口信息。如果 MAC 在最初获知的接口上停留 300 秒,则接口与 MAC 的关联被视为稳定,并且此接口被视为 MAC 的基本接口。如果 MAC 移动频繁发生在本地接口和 LSI 接口之间,而 MAC 的基本接口是 LSI,则本地接口被视为环路,必须禁用。
统计方法算法 — 这是用于禁用循环接口的辅助方法。如果某个接口超过 300 秒未获知 MAC,则该接口没有基本接口,因此使用统计方法。
如果没有基本接口信息(基本学习接口为空)的MAC开始移动,则学习该MAC在不同接口之间移动的统计信息。如果统计信息显示 MAC 从 LSI 移动到本地接口或从本地接口移动到本地接口,则本地接口被视为已循环并被禁用。
某些 MAC 可以在不同接口之间移动,例如,虚拟路由器冗余协议 (VRRP) 中的主要角色更改。无法维护此类 MAC 移动的基本接口,因为这会导致假设环路创建。因此,应将此类 MAC 配置为虚拟 MAC。虚拟 MAC 的示例包括 VRRP 的 00:00:5e:00:01:xx、热备用路由器协议 (HSRP) 的 00:00:0c:07:ac:xx、全局服务器负载平衡 (GSLB) 的 00:07:b4:00:01:xx 以及 VMotion 的 02:bf:xx:xx:xx:xx。
从 Junos OS 17.4R1 版开始,该 global-mac-move 语句取代 vpls-mac-move 了该语句。语句下的 global-mac-move 以下计时器有助于监控禁用的接口:
冷却时间 — 冷却时间从接口被禁用时开始。在此期间,路由实例中发生的任何 MAC 移动都将被忽略。这可以确保在路由实例上的给定时间内仅阻塞一个接口,并且仅在冷却计时器到期后才会阻塞另一个接口,前提是仍观察到给定的 MAC 移动。默认情况下,冷却时间为 30 秒。
接口恢复时间 — 当接口被禁用时,它将被永久禁用。配置接口恢复时间可确保在接口恢复持续时间结束后启用接口。建议将接口恢复时间配置为300秒以上。
统计方法等待时间 — 在观察MAC移动以确定MAC 地址没有基本IFL时是否存在环路后收集统计信息的时间。.默认情况下,统计方法等待计时器为 30 秒。
在建立 MAC 地址的基本学习接口之前,将统计方法算法用于 MAC 移动环路预防。当使用统计方法算法时,违规MAC 地址显示的MAC 地址为 00:00:00:00:00:00。在建立 MAC 地址的基本学习接口之前,这可能会导致具有路由环路的接口被错误识别。
也可以看看
配置由于 MAC 移动而导致的 VPLS 环路防御
在虚拟专用 LAN 服务 (VPLS) 部署中,如果之前学习的媒体访问控制 (MAC) 地址出现在不同的物理接口上,例如本地接口(千兆以太网接口)或标签交换接口 (LSI)),或者同一物理接口的不同单元中,如果此行为频繁发生,则被视为 MAC 移动。路由器根据 MAC 地址移动发生的次数和 MAC 地址移动发生的指定时间段报告 MAC 地址移动。VPLS 网络的配置错误可能会导致环路,从而导致 MAC 在不同接口之间频繁移动。这些作可用于通过在网络中禁用此类接口来纠正问题。以下两种方法可用于禁用接口:
基本学习接口(基本IFL)方法算法 — 这是用于禁用环路本地接口的主要方法。
统计方法算法 — 这是用于禁用环路本地接口的辅助方法。
某些虚拟 MAC 确实可以在不同接口之间移动,并且可以将此类 MAC 配置为忽略这些移动。冷却时间和统计方法等待时间在内部用于找出循环接口。接口恢复时间可以配置为自动启用由于网络环路而被禁用的接口。
开始在 VPLS 网络中配置环路预防之前:
配置 VPLS 拓扑。
配置 VPLS 路由实例。
在 VPLS 实例上启用 VPLS MAC 移动作。
配置路由和信令协议。
下面使用的命令vpls-mac-move替换global-mac-move了从 Junos OS 17.4R1 版开始的命令。
要在 VPLS 网络中配置环路防御,请执行以下作:
也可以看看
示例:在 VPLS 网络中配置由于 MAC 移动而导致的环路防御
此示例说明如何防止由于 MAC 在不同物理接口之间移动而导致 VPLS 网络中出现环路。
当在 VPLS 网络中检测到 MAC 移动时,Junos OS 可以使用基本的 IFL 或统计方法算法禁用接口,从而防止网络中的环路。
要求
此示例使用以下硬件和软件组件:
四个 MX 系列 5G 通用路由平台
在所有设备上运行 Junos OS 14.2 或更高版本
开始之前:
配置 VPLS 拓扑。
配置 VPLS 路由实例。
在 VPLS 实例上启用 VPLS MAC 移动作。
配置路由和信令协议。
概述
从 Junos OS 14.2 版开始,通过使用基本 IFL 方法或统计方法算法识别并禁用此类接口,可以防止由于不同物理接口之间的频繁 MAC 移动而导致的 VPLS 网络中环路的创建。
base IFL approach算法是主要方法。对于路由实例中的每个 MAC,将维护基本接口信息。如果 MAC 在最初获知的接口上停留 300 秒,则接口与 MAC 的关联将被视为稳定,并且此接口被视为 MAC 的基本接口。如果 MAC 移动频繁发生在本地接口和 LSI 接口之间,而 MAC 的基本接口是 LSI,则本地接口被视为环路,必须禁用。
该 statistical approach 算法是用于禁用环路接口的次要方法。如果某个接口超过 300 秒未获知 MAC,则该接口没有基本接口,因此使用统计方法。如果没有基本接口信息(基本学习接口为空)的MAC开始移动,则学习此类MAC在不同接口之间移动的统计信息。如果统计信息显示 MAC 从 LSI 移动到本地接口或从本地接口移动到本地接口,则本地接口被视为已循环并被禁用。
配置
CLI 快速配置
要快速配置此示例,请复制以下命令,将其粘贴到文本文件中,删除所有换行符,更改详细信息,以便与网络配置匹配,然后将命令复制并粘贴到层次结构级别的 [edit] CLI 中。
此示例使用的命令vpls-mac-move替换global-mac-move了从 Junos OS 17.4R1 版开始的命令。
PE0
set interfaces xe-0/0/0 unit 0 family inet address 198.51.100.8/24 set interfaces xe-0/0/0 unit 0 family mpls set interfaces xe-0/2/0 unit 0 family inet address 198.51.100.6/24 set interfaces xe-0/2/0 unit 0 family mpls set interfaces xe-0/3/0 vlan-tagging set interfaces xe-0/3/0 encapsulation vlan-vpls set interfaces xe-0/3/0 unit 600 encapsulation vlan-vpls set interfaces xe-0/3/0 unit 600 vlan-id 600 set interfaces ge-2/0/3 unit 0 family inet address 198.51.100.1/24 set interfaces ge-2/0/3 unit 0 family mpls set interfaces lo0 unit 0 family inet address 192.0.2.1/24 set routing-options router-id 192.0.2.1 set routing-options autonomous-system 701 set protocols mpls interface fxp0.0 disable set protocols mpls interface ge-2/0/3.0 set protocols mpls interface xe-0/2/0.0 set protocols mpls interface xe-0/0/0.0 set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ospf area 0.0.0.0 interface fxp0.0 disable set protocols ospf area 0.0.0.0 interface ge-2/0/3.0 interface-type p2p set protocols ospf area 0.0.0.0 interface ge-2/0/3.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-0/2/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-0/2/0.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-0/0/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-0/0/0.0 metric 10 set protocols ldp interface xe-0/0/0.0 set protocols ldp interface xe-0/2/0.0 set protocols ldp interface ge-2/0/3.0 set protocols ldp interface fxp0.0 disable set protocols ldp interface lo0.0 set protocols l2-learning global-mac-move threshold-time 30 set protocols l2-learning global-mac-move threshold-count 4 set protocols l2-learning global-mac-move cooloff-time 10 set protocols l2-learning global-mac-move statistical-approach-wait-time 10 set protocols l2-learning global-mac-move interface-recovery-time 5 set protocols l2-learning global-mac-move virtual-mac 00:00:5e:00:01:00/40 set routing-instances vpls_1 instance-type vpls set routing-instances vpls_1 interface xe-0/3/0.600 set routing-instances vpls_1 protocols vpls no-tunnel-services set routing-instances vpls_1 protocols vpls vpls-id 100 set routing-instances vpls_1 protocols vpls neighbor 192.0.2.2 set routing-instances vpls_1 protocols vpls neighbor 192.0.2.3 set routing-instances vpls_1 protocols vpls neighbor 192.0.2.4
PE1
set interfaces ge-0/0/3 unit 0 family inet address 198.51.100.2/24 set interfaces ge-0/0/3 unit 0 family mpls set interfaces xe-1/2/0 unit 0 family inet address 198.51.100.5/24 set interfaces xe-1/2/0 unit 0 family mpls set interfaces xe-1/2/1 unit 0 family inet address 198.51.100.3/24 set interfaces xe-1/2/1 unit 0 family mpls set interfaces xe-1/3/1 vlan-tagging set interfaces xe-1/3/1 encapsulation vlan-vpls set interfaces xe-1/3/1 unit 600 encapsulation vlan-vpls set interfaces xe-1/3/1 unit 600 vlan-id 600 set interfaces lo0 unit 0 family inet address 192.0.2.2/24 set routing-options router-id 192.0.2.2 set routing-options autonomous-system 701 set protocols mpls interface fxp0.0 disable set protocols mpls interface ge-0/0/3.0 set protocols mpls interface xe-1/2/1.0 set protocols mpls interface xe-1/2/0.0 set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ospf area 0.0.0.0 interface fxp0.0 disable set protocols ospf area 0.0.0.0 interface ge-0/0/3.0 interface-type p2p set protocols ospf area 0.0.0.0 interface ge-0/0/3.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-1/2/1.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-1/2/1.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-1/2/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-1/2/0.0 metric 10 set protocols ldp interface ge-0/0/3.0 set protocols ldp interface xe-1/2/0.0 set protocols ldp interface xe-1/2/1.0 set protocols ldp interface fxp0.0 disable set protocols ldp interface lo0.0 set protocols l2-learning global-mac-move threshold-time 30 set protocols l2-learning global-mac-move threshold-count 4 set protocols l2-learning global-mac-move cooloff-time 10 set protocols l2-learning global-mac-move statistical-approach-wait-time 10 set protocols l2-learning global-mac-move interface-recovery-time 10 set protocols l2-learning global-mac-move virtual-mac 00:00:5e:00:01:00/40 set routing-instances vpls_1 instance-type vpls set routing-instances vpls_1 interface xe-1/3/1.600 set routing-instances vpls_1 protocols vpls enable-mac-move-action set routing-instances vpls_1 protocols vpls no-tunnel-services set routing-instances vpls_1 protocols vpls vpls-id 100 set routing-instances vpls_1 protocols vpls neighbor 192.0.2.1
PE2
set interfaces xe-4/0/0 unit 0 family inet address 198.51.100.10/24 set interfaces xe-4/0/0 unit 0 family mpls set interfaces xe-4/1/0 unit 0 family inet address 198.51.100.4/24 set interfaces xe-4/1/0 unit 0 family mpls set interfaces xe-4/2/0 unit 0 family inet address 198.51.100.7/24 set interfaces xe-4/2/0 unit 0 family mpls set interfaces xe-4/3/0 vlan-tagging set interfaces xe-4/3/0 encapsulation vlan-vpls set interfaces xe-4/3/0 unit 600 encapsulation vlan-vpls set interfaces xe-4/3/0 unit 600 vlan-id 600 set interfaces lo0 unit 0 family inet address 192.0.2.3/24 set routing-options router-id 192.0.2.3 set routing-options autonomous-system 701 set protocols mpls interface fxp0.0 disable set protocols mpls interface xe-4/2/0.0 set protocols mpls interface xe-4/1/0.0 set protocols mpls interface xe-4/0/0.0 set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ospf area 0.0.0.0 interface fxp0.0 disable set protocols ospf area 0.0.0.0 interface xe-4/2/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-4/2/0.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-4/1/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-4/1/0.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-4/0/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-4/0/0.0 metric 10 set protocols ldp interface xe-4/0/0.0 set protocols ldp interface xe-4/1/0.0 set protocols ldp interface xe-4/2/0.0 set protocols ldp interface fxp0.0 disable set protocols ldp interface lo0.0 set protocols l2-learning global-mac-move threshold-time 30 set protocols l2-learning global-mac-move threshold-count 4 set protocols l2-learning global-mac-move threshold-count 5 set protocols l2-learning global-mac-move cooloff-time 10 set protocols l2-learning global-mac-move statistical-approach-wait-time 10 set protocols l2-learning global-mac-move interface-recovery-time 10 set protocols l2-learning global-mac-move virtual-mac 00:00:5e:00:01:00/40 set routing-instances vpls_1 instance-type vpls set routing-instances vpls_1 interface xe-4/3/0.600 set routing-instances vpls_1 protocols vpls enable-mac-move-action set routing-instances vpls_1 protocols vpls no-tunnel-services set routing-instances vpls_1 protocols vpls vpls-id 100 set routing-instances vpls_1 protocols vpls neighbor 192.0.2.1
PE3
set interfaces xe-1/0/0 unit 0 family inet address 198.51.100.9/24 set interfaces xe-1/0/0 unit 0 family mpls set interfaces xe-1/1/0 unit 0 family inet address 198.51.100.12/24 set interfaces xe-1/1/0 unit 0 family mpls set interfaces xe-1/2/0 unit 0 family inet address 198.51.100.11/24 set interfaces xe-1/2/0 unit 0 family mpls set interfaces xe-1/3/0 vlan-tagging set interfaces xe-1/3/0 encapsulation vlan-vpls set interfaces xe-1/3/0 unit 600 encapsulation vlan-vpls set interfaces xe-1/3/0 unit 600 vlan-id 600 set interfaces xe-2/3/0 vlan-tagging set interfaces xe-2/3/0 encapsulation vlan-vpls set interfaces xe-2/3/0 unit 600 encapsulation vlan-vpls set interfaces xe-2/3/0 unit 600 vlan-id 600 set interfaces lo0 unit 0 family inet address 192.0.2.4/24 set routing-options router-id 192.0.2.4 set routing-options autonomous-system 701 set protocols mpls interface fxp0.0 disable set protocols mpls interface xe-1/2/0.0 set protocols mpls interface xe-1/0/0.0 set protocols mpls interface xe-1/1/0.0 set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ospf area 0.0.0.0 interface fxp0.0 disable set protocols ospf area 0.0.0.0 interface xe-1/2/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-1/2/0.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-1/0/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-1/0/0.0 metric 10 set protocols ospf area 0.0.0.0 interface xe-1/1/0.0 interface-type p2p set protocols ospf area 0.0.0.0 interface xe-1/1/0.0 metric 10 set protocols ldp interface xe-1/0/0.0 set protocols ldp interface xe-1/1/0.0 set protocols ldp interface xe-1/2/0.0 set protocols ldp interface fxp0.0 disable set protocols ldp interface lo0.0 set protocols l2-learning global-mac-move threshold-time 30 set protocols l2-learning global-mac-move threshold-count 4 set protocols l2-learning global-mac-move cooloff-time 10 set protocols l2-learning global-mac-move statistical-approach-wait-time 10 set protocols l2-learning global-mac-move interface-recovery-time 10 set protocols l2-learning global-mac-move virtual-mac 00:00:52:00:01:00/40 set policy-options policy-statement pplb then load-balance per-packet set routing-instances vpls_1 instance-type vpls set routing-instances vpls_1 interface xe-1/3/0.600 set routing-instances vpls_1 interface xe-2/3/0.600 set routing-instances vpls_1 protocols vpls no-tunnel-services set routing-instances vpls_1 protocols vpls vpls-id 100 set routing-instances vpls_1 protocols vpls neighbor 192.0.2.1
配置设备 PE1
分步程序
下面的示例要求您在各个配置层级中进行导航。有关导航 CLI 的信息,请参阅 《CLI 用户指南》中的在配置模式下使用 CLI 编辑器。
要配置设备 PE1:
修改路由器的相应接口名称、地址和任何其他参数后,对路由器 PE0、PE2 和 PE3 路由器重复此过程。
配置接口。
[edit interfaces] user@PE1# set ge-0/0/3 unit 0 family inet address 198.51.100.2/24 user@PE1# set ge-0/0/3 unit 0 family mpls user@PE1# set xe-1/2/0 unit 0 family inet address 198.51.100.5/24 user@PE1# set xe-1/2/0 unit 0 family mpls user@PE1# set xe-1/2/1 unit 0 family inet address 198.51.100.3/24 user@PE1# set xe-1/2/1 unit 0 family mpls user@PE1# set xe-1/3/1 vlan-tagging user@PE1# set xe-1/3/1 encapsulation vlan-vpls user@PE1# set xe-1/3/1 unit 600 encapsulation vlan-vpls user@PE1# set xe-1/3/1 unit 600 vlan-id 600 user@PE1# set lo0 unit 0 family inet address 192.0.2.2/24
配置路由选项。
[edit routing-options] user@PE1# set router-id 192.0.2.2 user@PE1# set autonomous-system 701
在接口上配置 MPLS 协议。
[edit protocols mpls] user@PE1# set interface fxp0.0 disable user@PE1# set interface ge-0/0/3.0 user@PE1# set interface xe-1/2/1.0 user@PE1# set interface xe-1/2/0.0
配置 OSPF 协议。
[edit protocols ospf] user@PE1# set area 0.0.0.0 interface lo0.0 passive user@PE1# set area 0.0.0.0 interface fxp0.0 disable user@PE1# set area 0.0.0.0 interface ge-0/0/3.0 interface-type p2p user@PE1# set area 0.0.0.0 interface ge-0/0/3.0 metric 10 user@PE1# set area 0.0.0.0 interface xe-1/2/1.0 interface-type p2p user@PE1# set area 0.0.0.0 interface xe-1/2/1.0 metric 10 user@PE1# set area 0.0.0.0 interface xe-1/2/0.0 interface-type p2p user@PE1# set area 0.0.0.0 interface xe-1/2/0.0 metric 10
在接口上配置 LDP 协议。
[edit protocols ldp] user@PE1# set interface ge-0/0/3.0 user@PE1# set interface xe-1/2/0.0 user@PE1# set interface xe-1/2/1.0 user@PE1# set interface fxp0.0 disable user@PE1# set interface lo0.0
配置阈值时间和阈值计数以检测 MAC 移动。
[edit protocols l2-learning global-mac-move] user@PE1# set threshold-time 30 user@PE1# set threshold-count 4
配置 VPLS MAC 移动参数,如冷却时间、统计方法等待时间、接口恢复时间和虚拟 MAC。
[edit protocols l2-learning global-mac-move] user@PE1# set cooloff-time 10 user@PE1# set statistical-approach-wait-time 10 user@PE1# set interface-recovery-time 10 user@PE1# set virtual-mac 00:00:5e:00:01:00/40
在 VPLS 实例vpls_1的接口上启用 MAC 移动作。
[edit routing-instances vpls_1] user@PE1# set instance-type vpls user@PE1# set interface xe-1/3/1.600 user@PE1# set protocols vpls enable-mac-move-action user@PE1# set protocols vpls no-tunnel-services user@PE1# set protocols vpls vpls-id 100 user@PE1# set protocols vpls neighbor 192.0.2.1
结果
在配置模式下,输入 show interfaces、 show protocols、 show routing-options和 show routing-instances 命令以确认您的配置。如果输出未显示预期的配置,请重复此示例中的说明以更正配置。
user@PE1# show interfaces
ge-0/0/3 {
unit 0 {
family inet {
address 198.51.100.2/24;
}
family mpls;
}
}
xe-1/2/0 {
unit 0 {
family inet {
address 198.51.100.5/24;
}
family mpls;
}
}
xe-1/2/1 {
unit 0 {
family inet {
address 198.51.100.3/24;
}
family mpls;
}
}
xe-1/3/1 {
vlan-tagging;
encapsulation vlan-vpls;
unit 600 {
encapsulation vlan-vpls;
vlan-id 600;
}
}
lo0 {
unit 0 {
family inet {
address 192.0.2.2/24;
}
}
}
user@PE1# show protocols
mpls {
interface fxp0.0 {
disable;
}
interface ge-0/0/3.0;
interface xe-1/2/1.0;
interface xe-1/2/0.0;
}
ospf {
area 0.0.0.0 {
interface lo0.0 {
passive;
}
interface fxp0.0 {
disable;
}
interface ge-0/0/3.0 {
interface-type p2p;
metric 10;
}
interface xe-1/2/1.0 {
interface-type p2p;
metric 10;
}
interface xe-1/2/0.0 {
interface-type p2p;
metric 10;
}
}
}
ldp {
interface ge-0/0/3.0;
interface xe-1/2/0.0;
interface xe-1/2/1.0;
interface fxp0.0 {
disable;
}
interface lo0.0;
}
l2-learning {
global-mac-move {
threshold-time 30;
threshold-count 4;
}
global-mac-move {
cooloff-time 10;
statistical-approach-wait-time 10;
interface-recovery-time 10;
virtual-mac 00:00:5e:00:01:00/40;
}
}
user@PE1# show routing-instances
vpls_1 {
instance-type vpls;
interface xe-1/3/1.600;
protocols {
vpls {
enable-mac-move-action;
no-tunnel-services;
vpls-id 100;
neighbor 192.0.2.1;
}
}
}
如果完成设备配置,请从配置模式进入。commit
验证
验证配置是否工作正常。
- 验证 VPLS 网络中的 MAC 移动
- 验证 VPLS 实例中的 MAC 移动
- 验证 VPLS 网络中的 MAC 移动缓冲区
- 验证基本 IFL 方法算法的 VPLS MAC 表
- 验证接口是否已禁用
- 验证统计方法算法的 VPLS MAC 表
验证 VPLS 网络中的 MAC 移动
目的
验证是否在 VPLS 网络中观察到 MAC 移动。
行动
在作模式下,运行 show vpls mac-move-action 设备 PE1 的命令。
user@PE1> show vpls mac-move-action
Instance: vpls_1
Local interface: xe-1/3/1.600, Index: 341
Algorithm used : Base IFL
Time rec : 02:30:35
Recovery timer : Yes
意义
输出显示实例名称、本地接口和使用的算法,指示在 VPLS 网络中观察到 VPLS MAC 移动。
验证 VPLS 实例中的 MAC 移动
目的
验证是否在 VPLS 实例中观察到 MAC 移动。
行动
在作模式下,运行 show vpls mac-move-action instance instance-name 设备 PE1 的命令。
user@PE1> show vpls mac-move-action instance vpls_1
Instance: vpls_1
Local interface: xe-1/3/1.600, Index: 341
Algorithm used : Base IFL
Time rec : 02:29:35
Recovery timer : Yes
意义
输出显示本地接口和所用算法,指示在 VPLS 实例中观察到已观察到 VPLS MAC 移动。
验证 VPLS 网络中的 MAC 移动缓冲区
目的
验证 MAC 移动缓冲区,以监控 VPLS 网络中发生的 MAC 移动。
行动
在作模式下,运行 show l2-learning mac-move-buffer 设备 PE1 的命令。
user@PE1> show l2-learning mac-move-buffer
MAC Time Bridge
Address Rec. Domain
00:10:00:01:00:09 03:26:00 __vpls_1__
00:10:00:01:00:05 03:26:00 __vpls_1__
00:10:00:01:00:03 03:26:00 __vpls_1__
00:10:00:01:00:05 03:26:00 __vpls_1__
00:10:00:01:00:08 03:26:00 __vpls_1__
00:10:00:01:00:01 03:26:00 __vpls_1__
00:10:00:01:00:03 03:26:00 __vpls_1__
00:10:00:01:00:01 03:26:00 __vpls_1__
00:10:00:01:00:00 03:26:00 __vpls_1__
00:10:00:01:00:01 03:26:01 __vpls_1__
00:10:00:01:00:06 03:26:01 __vpls_1__
00:10:00:01:00:02 03:26:01 __vpls_1__
00:10:00:01:00:08 03:26:01 __vpls_1__
00:10:00:01:00:00 03:26:01 __vpls_1__
00:10:00:01:00:01 03:26:01 __vpls_1__
00:10:00:01:00:09 03:26:01 __vpls_1__
验证基本 IFL 方法算法的 VPLS MAC 表
目的
验证 MAC 地址的基本学习接口。.
行动
在作模式下,运行 show vpls mac-table extensive 命令可获取 VPLS MAC 表的广泛信息。
user@PE1> show vpls mac-table extensive
MAC address: 00:10:00:01:00:00
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: lsi.1049165
Base learning interface: lsi.1049165
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 0 Sequence number: 1
Learning mask: 0x00000001
MAC address: 00:10:00:01:00:01
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: lsi.1049165
Base learning interface: lsi.1049165
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 0 Sequence number: 1
Learning mask: 0x00000001
MAC address: 00:10:00:01:00:02
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: lsi.1049165
Base learning interface: lsi.1049165
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 0 Sequence number: 1
Learning mask: 0x00000001
MAC address: 00:10:00:01:00:03
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: lsi.1049165
Base learning interface: lsi.1049165
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 0 Sequence number: 1
Learning mask: 0x00000001
意义
命令 show vpls mac-table extensive 输出显示 MAC 地址的基本学习接口。
验证接口是否已禁用
目的
验证 MAC 地址的基本学习接口是否已禁用。
行动
在作模式下,运行 show interfaces interface-name 设备 PE1 的命令。
user@PE1> show interfaces xe-1/3/1.600
Logical interface xe-1/3/1.600 (Index 341) (SNMP ifIndex 2864)
Flags: Up Link-Layer-Down SNMP-Traps 0x4000 VLAN-Tag [ 0x8100.600 ] Encapsulation: VLAN-VPLS
Input packets : 2234018970
Output packets: 2234728895
Protocol vpls, MTU: 1518
Flags: Is-Primary
意义
输出中的标志 link-layer-down 表示接口已禁用。
验证统计方法算法的 VPLS MAC 表
目的
验证统计方法算法的 VPLS MAC 表。
行动
在作模式下,运行 show vpls mac-table extensive 设备 PE1 的命令。
user@PE1> show vpls mac-table extensive
MAC address: 00:10:00:01:00:00
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: xe-1/3/1.600
Base learning interface: NULL
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 3 Sequence number: 442
Learning mask: 0x00000002
MAC address: 00:10:00:01:00:01
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: xe-1/3/1.600
Base learning interface: NULL
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 3 Sequence number: 442
Learning mask: 0x00000003
MAC address: 00:10:00:01:00:02
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: xe-1/3/1.600
Base learning interface: NULL
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 3 Sequence number: 442
Learning mask: 0x00000002
MAC address: 00:10:00:01:00:03
Routing instance: vpls_1
Bridging domain: __vpls_1__, VLAN : NA
Learning interface: xe-1/3/1.600
Base learning interface: NULL
Layer 2 flags: in_hash,in_ifd,in_ifl,in_vlan,in_rtt,kernel,in_ifbd
Epoch: 3 Sequence number: 442
Learning mask: 0x00000002
意义
为 Base learning interface 空值,表示正在使用统计方法。
变更历史表
是否支持某项功能取决于您使用的平台和版本。使用 功能资源管理器 确定您的平台是否支持某个功能。
