示例:使用 OVSDB 配置 VXLAN 到 VPLS 拼接
虚拟可扩展 LAN (VXLAN) 可以在支持 VPLS 的网络中与 Open vSwitch 数据库 (OVSDB) 管理协议一起使用,将虚拟化数据中心拼接到第 2 层 VPN 网络中。此配置允许使用第 2 层 VPN 的不同数据中心之间实现无缝互连,无论它是虚拟化的、物理的还是两者。
要求
此示例使用以下硬件和软件组件:
两台运行 Junos OS 14.1R2 或更高版本的 MX 系列路由器
两台使用 OVSDB 软件包运行 Junos OS 14.1R2 或更高版本的 MX 系列路由器。此软件包的版本必须与设备上运行的 Junos OS 版本相同。
一台 EX9200 交换机
一个 VMware NSX 控制器
NSX 管理器
开始配置之前,必须执行以下任务:
在 NSX Manager 或 NSX API 中,为 OVSDB 管理的每个 VXLAN 配置一个逻辑交换机。此示例实施两个 OVSDB 托管的 VXLAN,因此必须配置两个逻辑交换机。配置每个逻辑交换机后,NSX 将自动生成该逻辑交换机的通用唯一标识符 (UUID)。如果尚未检索,请检索每个逻辑交换机的 UUID。示例 UUID 为 28805c1d-0122-495d-85df-19abd647d772。在瞻博网络设备上配置等效 VXLAN 时,必须使用逻辑交换机的 UUID 作为网桥域名。
有关逻辑交换机和 VXLAN 的更多信息,请参阅 了解如何手动配置 OVSDB 托管的 VXLAN。
创建 SSL 私有密钥和证书,并将其安装在
/var/db/certs
瞻博网络设备的目录中。有关更多信息,请参阅 在瞻博网络设备上创建和安装 SSL 密钥和证书,以便与 SDN 控制器连接。
概述
在此示例中,四个 MX 系列路由器配置为协同工作,以实现 VXLAN 到虚拟专用 LAN 服务 (VPLS) 拼接。每台路由器在配置中都扮演不同的角色。下图显示了这些 MX 系列路由器的拓扑结构。MX1 是处理第 3 层流量和协议的核心路由器。MX2 是 VXLAN 网关路由器,用作虚拟隧道端点 (VTEP),可处理第 2 层、VPLS 和 VXLAN 的交换。MX3 路由器配置为处理 VPLS 流量。MX4 路由器配置为 VTEP,用于接受并解封装 VXLAN 数据包。
拓扑
配置
要配置 VXLAN 到 VPLS 与 OVSDB 拼接:
CLI 快速配置
要快速配置此示例,请复制以下命令,将其粘贴到文本文件中,删除所有换行符,更改详细信息,以便与配置匹配,将命令复制并粘贴到 [edit
] 层次结构级别的 CLI 中,然后从配置模式进入 commit
。
MX1
set interfaces lo0 unit 0 family inet address 10.255.181.13/32 primary set interfaces ge-1/1/2 unit 0 family inet address 10.30.30.2/30 set interfaces xe-0/0/0 unit 0 family inet address 10.20.20.2/30 set protocols ospf area 0.0.0.0 interface all
MX2
set interfaces lo0 unit 0 family inet address 10.255.181.72/32 primary set lag-options interfaces <ae*> mtu 9192 set lag-options interfaces <ae*> aggregated ether-options minimum-links 1 set chassis aggregated-devices ethernet device-count 40 set chassis fpc 1 pic 0 tunnel-services bandwidth 10g set chassis network-services enhanced-ip set interfaces xe-1/2/0 gigether-options 802.3ad ae1 set interfaces xe-0/0/0 unit 0 family inet address 10.20.20.1/30 set interfaces ge-7/0/9 vlan tagging set interfaces ge-7/0/9 unit 1 vlan-id 3 set interfaces ge-7/0/9 unit 1 family vpls set interfaces xe-10/3/0 vlan tagging set interfaces xe-10/3/0 unit 1 vlan-id 3 set interfaces xe-10/3/0 unit 0 family vpls set interfaces ae1 unit 0 family inet address 10.1.1.1/30 set interfaces ae1 unit 0 family mpls set routing-options autonomous-system 100 set protocols rsvp interface all set protocols mpls no cspf set protocols mpls label-switched-path-to-mx3 to 10.255.181.98 set protocols mpls interface all set protocols bgp family l2vpn signaling set protocols bgp group ibgp type internal set protocols bgp group ibgp neighbor 10.255.181.98 local-address 10.255.181.72 set protocols ospf area 0.0.0.0 interface xe-0/0/0.0 set protocols ospf area 0.0.0.0 interface fxp0.0 disable set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ospf area 0.0.0.0 interface ae1.0 set protocols ovsdb traceoptions file ovsdb.log size 100m files 10 set protocols ovsdb traceoptions file ovsdb.level all set protocols ovsdb traceoptions file ovsdb.flag all set protocols ovsdb interfaces xe-10/3/0.1 set protocols ovsdb interfaces ge-7/0/9.1 set protocols ovsdb controller 192.168.182.45 protocol ssl port 6632 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 vtep-source-interface lo0.0 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 instance-type vpls set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 vlan-id 3 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 interface ge-7/0/9.1 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 interface xe-10/3/0.1 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 routing-interface irb.3 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan ovsdb-managed set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan vni 3 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 route-distinguisher 10.255.181.72:3 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 vrf-target target:3:3 set routing-instances 24a76aff-7e61-4520-a78d-3eca26ad7510 protocols vpls site mx2 site-identifier 1
MX3
set interfaces lo0 unit 0 family inet address 127.0.0.1/32 set interfaces lo0 unit 0 family inet address 10.255.181.98/32 primary set lag-options interfaces <ae*> mtu 9192 set lag-options interfaces <ae*> aggregated-ether-options minimum-links 1 set lag-options interfaces <ae*> aggregated-ether-options lacp active set interfaces xe-0/0/0 gigether-options 802.3ad ae1 set interfaces xe-0/0/1 gigether-options 802.3ad ae1 set interfaces xe-0/0/3 vlan tagging set interfaces xe-0/0/3 unit 1 vlan-id 3 set interfaces xe-0/0/3 unit 1 family vpls set interfaces ae1 unit 0 family inet address 10.1.1.2/30 set interfaces ae1 unit 0 family mpls set routing-options autonomous-system 100 set protocols rsvp interface all set protocols mpls no-cspf set protocols mpls label-switched-path-to-mx2 to 10.255.181.72 set protocols mpls interface all set protocols bgp family l2vpn signaling set protocols bgp group ibgp type internal set protocols bgp group ibgp neighbor 10.255.181.72 local-address 10.255.181.98 set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ospf area 0.0.0.0 interface ae1.0 set routing-instances vpls3 instance-type vpls set routing-instances vpls3 vlan-id 3 set routing-instances vpls3 interface xe-0/0/3.1 set routing-instances vpls3 route-distinguisher 10.255.181.98:3 set routing-instances vpls3 vrf-target target:3:3 set routing-instances vpls3 protocols vpls no-tunnel-services set routing-instances vpls3 protocols vpls site mx3 site-identifier 2
MX4
set interfaces lo0 unit 0 family inet address 10.255.181.43/32 primary set interfaces xe-0/0/0 vlan-tagging set interfaces xe-0/0/0 encapsulation flexible-ethernet-services set interfaces xe-0/0/0 unit 0 family bridge interface-mode trunk set interfaces xe-0/0/0 unit 0 family bridge vlan-id-list 1-10 set interfaces ge-0/2/6 unit 0 family inet address 10.30.30.1/30 set protocols ospf area 0.0.0.0 interface ge-0/2/6.0 set protocols ospf area 0.0.0.0 interface fxp0.0 disable set protocols ospf area 0.0.0.0 interface lo0.0 passive set protocols ovsdb traceoptions file ovsdb.log size 100m files 10 set protocols ovsdb traceoptions level all set protocols ovsdb traceoptions flag all set protocols ovsdb interfaces xe-0/0/0.0 set protocols ovsdb controller 192.168.182.45 protocol ssl port 6632 set routing-instances default-vs1 vtep-source-interface lo0.0 set routing-instances default-vs1 instance-type virtual-switch set routing-instances default-vs1 interface xe-0/0/0.1 set bridge-domains 24a76aff-7e61-4520-a78d-3eca26ad7510 vlan-id 3 set bridge-domains 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan ovsdb-managed set bridge-domains 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan vni 3 set bridge-domains 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan ingress-node-replication set switch-options vtep-source-interface lo0.0
配置 MX1
逐步过程
要配置的第一个路由器是核心路由器。这款 MX 系列路由器可处理网络其余部分的第 3 层流量和协议。
要配置 MX1 路由器:
指定环路接口的 IPv4 地址。
[edit interfaces] user@MX1# set lo0 unit 0 family inet address 10.255.181.13/32 primary
配置第 3 层网络。
[edit interfaces] user@MX1# set ge-1/1/2 unit 0 family inet address 10.30.30.2/30 user@MX1# set xe-0/0/0 unit 0 family inet address 10.20.20.2/30
在所有接口上启用 OSPF。
[edit protocols] user@MX1# set ospf area 0.0.0.0 interface all
配置 MX2
逐步过程
要配置的第二个路由器是 VXLAN 网关路由器。此 MX 系列路由器配置为 VTEP,可处理第 2 层、VPLS 和 VXLAN 的交换。
要配置 MX2 路由器:
为 VXLAN 网关配置接口。
[edit interfaces] user@MX2# set lo0 unit 0 family inet address 10.255.181.72/32 primary user@MX2# set xe-1/2/0 gigether-options 802.3ad ae1 user@MX2# set xe-0/0/0 unit 0 family inet address 10.20.20.1/30 user@MX2# set ge-7/0/9 vlan tagging user@MX2# set ge-7/0/9 unit 1 vlan-id 3 user@MX2# set ge-7/0/9 unit 1 family vpls user@MX2# set xe-10/3/0 vlan tagging user@MX2# set xe-10/3/0 unit 1 vlan-id 3 user@MX2# set xe-10/3/0 unit 0 family vpls user@MX2# set ae1 unit 0 family inet address 10.1.1.1/30 user@MX2# set ae1 unit 0 family mpls
设置 LAG 选项
[edit lag-options] user@MX2# set interfaces <ae*> mtu 9192 user@MX2# set interfaces <ae*> aggregated ether-options minimum-links 1
配置机箱设置。
[edit chassis] user@MX2# set aggregated-devices ethernet device-count 40 user@MX2# set fpc 1 pic 0 tunnel-services bandwidth 10g user@MX2# set network-services enhanced-ip
配置路由选项。
[edit routing-options] user@MX2# set autonomous-system 100
设置 RSVP、MPLS 和 BGP 协议。
[edit protocols] user@MX2# set rsvp interface all user@MX2# set mpls no cspf user@MX2# set mpls label-switched-path-to-mx3 to 10.255.181.98 user@MX2# set mpls interface all user@MX2# set bgp family l2vpn signaling user@MX2# set bgp group ibgp type internal user@MX2# set bgp group ibgp neighbor 10.255.181.98 local-address 10.255.181.72
配置 OSPF 接口设置。
[edit protocols] user@MX2# set ospf area 0.0.0.0 interface xe-0/0/0.0 user@MX2# set ospf area 0.0.0.0 interface fxp0.0 disable user@MX2# set ospf area 0.0.0.0 interface lo0.0 passive user@MX2# set ospf area 0.0.0.0 interface ae1.0
设置 OVSDB 跟踪操作。
[edit protocols] user@MX2# set ovsdb traceoptions file ovsdb.log size 100m files 10 user@MX2# set ovsdb traceoptions file ovsdb.level all user@MX2# set ovsdb traceoptions file ovsdb.flag all
指定由 OVSDB 管理接口 xe-10/3/0.1 和 ge-7/0/9.1。
[edit protocols] user@MX2# set ovsdb interfaces xe-10/3/0.1 user@MX2# set ovsdb interfaces ge-7/0/9.1
配置与 NSX 控制器的连接。
[edit protocols] user@MX2# set ovsdb controller 192.168.182.45 protocol ssl port 6632
创建具有 VXLAN 功能的 VPLS 路由实例。
[edit routing-instances] user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vtep-source-interface lo0.0 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 instance-type vpls user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vlan-id 3 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 interface ge-7/0/9.1 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 interface xe-10/3/0.1 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 routing-interface irb.3 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan ovsdb-managed user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan vni 3 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 route-distinguisher 10.255.181.72:3 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vrf-target target:3:3 user@MX2# set 24a76aff-7e61-4520-a78d-3eca26ad7510 protocols vpls site mx2 site-identifier 1
注意:完成此配置后,必须配置网关,该网关相当于硬件 VTEP 的 NSX。此配置实施一个硬件 VTEP,因此必须使用 NSX Manager 或 NSX API 配置一个网关、一个网关服务和一个逻辑交换机端口。有关您必须执行的任务以及关键 NSX Manager 配置详细信息的更多信息,请参阅 用作虚拟隧道端点的瞻博网络设备的 VMware NSX 配置。
配置 MX3
逐步过程
必须配置第三个 MX 系列路由器来处理 VPLS 流量。
要配置 MX3 路由器:
指定环路接口的 IPv4、IPv6 和 ISO 地址。
[edit interfaces] user@MX3# set lo0 unit 0 family inet address 127.0.0.1/32 user@MX3# set lo0 unit 0 family inet address 10.255.181.98/32 primary
配置网络接口。
[edit interfaces] user@MX3# set xe-0/0/0 gigether-options 802.3ad ae1 user@MX3# set xe-0/0/1 gigether-options 802.3ad ae1 user@MX3# set xe-0/0/3 vlan tagging user@MX3# set xe-0/0/3 unit 1 vlan-id 3 user@MX3# set xe-0/0/3 unit 1 family vpls user@MX3# set ae1 unit 0 family inet address 10.1.1.2/30 user@MX3# set ae1 unit 0 family mpls
设置 LAG 选项
[edit lag-options] user@MX3# set interfaces <ae*> mtu 9192 user@MX3# set interfaces <ae*> aggregated-ether-options minimum-links 1 user@MX3# set interfaces <ae*> aggregated-ether-options lacp active
配置路由选项。
[edit routing-options] user@MX3# set autonomous-system 100
设置 RSVP、MPLS 和 BGP 协议。
[edit protocols] user@MX3# set rsvp interface all user@MX3# set mpls no cspf user@MX3# set mpls label-switched-path-to-mx2 to 10.255.181.72 user@MX3# set mpls interface all user@MX3# set bgp family l2vpn signaling user@MX3# set bgp group ibgp type internal user@MX3# set bgp group ibgp neighbor 10.255.181.72 local-address 10.255.181.98
配置 OSPF 接口设置。
[edit protocols] user@MX3# set ospf area 0.0.0.0 interface lo0.0 passive user@MX3# set ospf area 0.0.0.0 interface ae1.0
创建 VPLS 路由实例。
[edit routing-instances] set vpls3 instance-type vpls set vpls3 vlan-id 3 set vpls3 interface xe-0/0/3.1 set vpls3 route-distinguisher 10.255.181.98:3 set vpls3 vrf-target target:3:3 set vpls3 protocols vpls no-tunnel-services set vpls3 protocols vpls site mx3 site-identifier 2
配置 MX4
逐步过程
第四台 MX 系列路由器配置为 VTEP,用于接受和解封装 VXLAN 数据包。
要配置 MX4 路由器:
指定环路接口的 IPv4、IPv6 和 ISO 地址。
[edit interfaces] user@MX4# set lo0 unit 0 family inet address 10.255.181.43/32 primary
配置接口。
[edit interfaces] user@MX4# set xe-0/0/0 vlan-tagging user@MX4# set xe-0/0/0 encapsulation flexible-ethernet-services user@MX4# set xe-0/0/0 unit 0 family bridge interface-mode trunk user@MX4# set xe-0/0/0 unit 0 family bridge vlan-id-list 1-10 user@MX4# set ge-0/2/6 unit 0 family inet address 10.30.30.1/30
配置 OSPF 接口设置。
[edit protocols] user@MX4# set ospf area 0.0.0.0 interface ge-0/2/6.0 user@MX4# set ospf area 0.0.0.0 interface fxp0.0 disable user@MX4# set ospf area 0.0.0.0 interface lo0.0 passive
设置 OVSDB 跟踪操作。
[edit protocols] user@MX4# set ovsdb traceoptions file ovsdb.log size 100m files 10 user@MX4# set ovsdb traceoptions level all user@MX4# set ovsdb traceoptions flag all
指定由 OVSDB 管理 xe-0/0/0.0 接口。
[edit protocols] user@MX4# set ovsdb interfaces xe-0/0/0.0
配置与 NSX 控制器的连接。
[edit protocols] user@MX4# set ovsdb controller 192.168.182.45 protocol ssl port 6632
配置 VPLS 接口。
[edit routing-instances] user@MX4# set default-vs1 vtep-source-interface lo0.0 user@MX4# set default-vs1 instance-type virtual-switch user@MX4# set default-vs1 interface xe-0/0/0.1
配置一组支持 VXLAN 的网桥域。
[edit bridge-domains] user@MX4# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vlan-id 3 user@MX4# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan ovsdb-managed user@MX4# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan vni 3 user@MX4# set 24a76aff-7e61-4520-a78d-3eca26ad7510 vxlan ingress-node-replication
配置环路接口用作隧道源地址。
[edit switch-options] user@MX4# set vtep-source-interface lo0.0
注意:完成此配置后,必须配置网关,该网关相当于硬件 VTEP 的 NSX。此配置实施一个硬件 VTEP,因此必须使用 NSX Manager 或 NSX API 配置一个网关、一个网关服务和一个逻辑交换机端口。有关您必须执行的任务以及关键 NSX Manager 配置详细信息的更多信息,请参阅“瞻博网络设备用作虚拟隧道端点的 VMware NSX 配置”。
结果
在配置模式下,在每台路由器上输入以下命令,以确认您的配置。如果输出未显示预期的配置,请重复此示例中的说明,以更正配置。
验证
确认配置工作正常。
验证 MX1
目的
验证您在 MX1 上的配置。
行动
验证接口配置是否正确。
user@MX1# show interface
lo0 { unit 0 { family inet { address 10.255.181.13/32 { primary; } } } } ge-1/1/2 { unit 0 { family inet { address 10.30.30.2/30; } } } xe-0/0/0 { unit 0 { family inet { address 10.20.20.2/30; } } }
验证 OSPF 配置是否正确。
user@MX1# show protocols
ospf { area 0.0.0.0 { interface all; } }
验证 MX2
目的
验证您在 MX2 上的配置。
行动
验证接口配置是否正确。
user@MX2# show interfaces
lo0 { unit 0 { family inet { address 10.255.181.72/32 { primary; } } } } xe-1/2/0 { gigether-options { 802.3ad ae1; } } xe-0/0/0 { unit 0 { family inet { address 10.20.20.1/30; } } } ge-7/0/9 { vlan-tagging; unit 0 { family vpls; } unit 1 { vlan-id 3; } } xe-10/3/0 { vlan-tagging; unit 0 { family vpls; } unit 1 { vlan-id 3; } } ae1 { unit 0 { family inet { address 10.1.1.1/30; } family mpls; } }
验证 OSPF 配置是否正确。
user@MX2# show protocols ospf
ospf { area 0.0.0.0 { interface xe-0/0/0.0; interface fxp0.0 { disable; } interface lo0.0 { passive; } interface ae1.0; } }
验证 OVSDB 配置是否正确。
user@MX2# show protocols ovsdb
ovsdb { traceoptions { file ovsdb.log size 100m files 10; level all; flag all; } interfaces { xe-10/3/0.1; ge-7/0/9.0; ge-7/0/9.1; } controller 192.168.182.45 { protocol { ssl port 6632; } } }
验证 default-VS1
路由实例配置。
user@MX2# show routing-instances
routing-instances { 24a76aff-7e61-4520-a78d-3eca26ad7510 { vtep-source-interface lo0.0; instance-type vpls; vlan-id 3; interface ge-7/0/9.1; interface xe-10/3/0.1; routing-interface irb.3; vxlan { ovsdb-managed; vni 3; encapsulate-inner-vlan; decapsulate-accept-inner-vlan; ingress-node-replication; } route-distinguisher 10.255.181.72:3; vrf-target target:3:3; protocols { vpls { traceoptions { file vpls.log; flag all; } site MX2 { site-identifier 1; } } } } cadbc185-f60f-48a6-93fd-dc14a6420c60 { vtep-source-interface lo0.0; instance-type vpls; vlan-id 2; interface ge-7/0/9.0; interface xe-10/3/0.0; routing-interface irb.2; vxlan { ovsdb-managed; vni 2; encapsulate-inner-vlan; decapsulate-accept-inner-vlan; ingress-node-replication; } route-distinguisher 10.255.181.72:10; vrf-target target:10:10; protocols { vpls { traceoptions { file vpls.log; flag all; } site MX2 { site-identifier 1; } } } } vpls11 { vtep-source-interface lo0.1; instance-type vpls; vlan-id 11; interface ge-7/0/9.11; interface xe-10/3/0.11; routing-interface irb.11; vxlan { ovsdb-managed; vni 11; ingress-node-replication; } route-distinguisher 10.255.181.72:11; vrf-target target:11:11; protocols { vpls { traceoptions { file vpls.log; flag all; } site MX2 { site-identifier 1; } } } } vpls12 { vtep-source-interface lo0.1; instance-type vpls; vlan-id 12; interface ge-7/0/9.12; interface xe-10/3/0.12; routing-interface irb.12; vxlan { ovsdb-managed; vni 12; ingress-node-replication; } route-distinguisher 10.255.181.72:12; vrf-target target:12:12; protocols { vpls { traceoptions { file vpls.log; flag all; } site mx2 { site-identifier 1; } } } } vpls13 { vtep-source-interface lo0.1; instance-type vpls; vlan-id 13; interface ge-7/0/9.13; interface xe-10/3/0.13; routing-interface irb.13; vxlan { vni 13; multicast-group 233.252.0.13; } route-distinguisher 10.255.181.72:13; vrf-target target:13:13; protocols { vpls { traceoptions { file vpls.log; flag all; } site mx2 { site-identifier 1; } } } } vpls14 { vtep-source-interface lo0.1; instance-type vpls; vlan-id 14; interface ge-7/0/9.14; interface xe-10/3/0.14; routing-interface irb.14; vxlan { vni 14; multicast-group 233.252.0.14; } route-distinguisher 10.255.181.72:14; vrf-target target:14:14; protocols { vpls { traceoptions { file vpls.log; flag all; } site mx2 { site-identifier 1; } } } } vpls15 { vtep-source-interface lo0.1; instance-type vpls; vlan-id 15; interface ge-7/0/9.15; interface xe-10/3/0.15; routing-interface irb.15; vxlan { vni 15; multicast-group 233.252.0.15; } route-distinguisher 10.255.181.72:15; vrf-target target:15:15; protocols { vpls { traceoptions { file vpls.log; flag all; } site mx2 { site-identifier 1; } } } } vpls4 { vtep-source-interface lo0.0; instance-type vpls; vlan-id 4; interface ge-7/0/9.4; interface xe-10/3/0.4; routing-interface irb.4; vxlan { vni 4; multicast-group 233.252.0.4; } route-distinguisher 10.255.181.72:4; vrf-target target:4:4; protocols { vpls { traceoptions { file vpls.log; flag all; } site mx2 { site-identifier 1; } } } } vpls5 { vtep-source-interface lo0.0; instance-type vpls; vlan-id 5; interface ge-7/0/9.5; interface xe-10/3/0.5; routing-interface irb.5; vxlan { vni 5; multicast-group 233.252.0.5; } route-distinguisher 10.255.181.72:5; vrf-target target:5:5; protocols { vpls { traceoptions { file vpls.log; flag all; } site mx2 { site-identifier 1; } } } } vrf1 { instance-type vrf; interface ae2.0; interface lo0.1; route-distinguisher 100:100; vrf-target target:100:100; protocols { ospf { area 0.0.0.0 { interface ae2.0; interface lo0.1 { passive; } } } pim { rp { static { address 10.255.181.13; } } interface all; } } } }
验证 vrf1
路由实例配置。
user@MX2# show routing-instances
24a76aff-7e61-4520-a78d-3eca26ad7510 { vtep-source-interface lo0.0; instance-type vpls; vlan-id 3; interface ge-7/0/9.1; interface xe-10/3/0.1; routing-interface irb.3; vxlan { ovsdb-managed; vni 3; } route-distinguisher 10.255.181.72:3; vrf-target target:3:3; protocols { vpls { site mx2 { site-identifier 1; } } } }
验证 MX3
目的
验证您在 MX3 上的配置。
行动
验证接口配置是否正确。
user@MX3# show interfaces
xe-0/0/0 { gigether-options { 802.3ad ae1; } } xe-0/0/1 { gigether-options { 802.3ad ae1; } } xe-0/0/3 { vlan-tagging; unit 1 { vlan-id 3; family vpls; } } ae1 { unit 0 { family inet { address 10.1.1.2/30; } family mpls; } }
验证 RSVP、MPLS、BGP 和 OSPF 协议配置是否正确。
user@MX3# show protocols
protocols { rsvp { interface all; } mpls { no-cspf; label-switched-path to-mx2 { to 10.255.181.72; } interface all; } bgp { family l2vpn { signaling; } group ibgp { type internal; neighbor 10.255.181.72 { local-address 10.255.181.98; } } } ospf { area 0.0.0.0 { interface lo0.0 { passive; } interface ae1.0; } } }
验证 VPLS 路由实例配置。
user@MX3# show routing-instances
routing-instances { vpls3 { instance-type vpls; vlan-id 3; interface xe-0/0/3.1; route-distinguisher 10.255.181.98:3; vrf-target target:3:3; protocols { vpls { no-tunnel-services; site mx3 { site-identifier 2; } } } } }
验证 MX4
目的
验证您在 MX4 上的配置。
行动
验证全局组接口配置是否正确。
user@MX4# show groups global interfaces
验证接口配置是否正确。
user@MX4# show interfaces
lo0 { unit 0 { family inet { address 10.255.181.43/32 { primary; } } } } xe-0/0/0 { vlan-tagging; encapsulation flexible-ethernet-services; unit 0 { family bridge { interface-mode trunk; vlan-id-list 1-10; } } } ge-0/2/6 { unit 0 { family inet { address 30.30.30.1/30; } } }
验证 OSPF 接口设置配置是否正确。
user@MX4# show protocols ospf area 0.0.0.0 { interface ge-0/2/6.0; interface fxp0.0 { disable; } interface lo0.0 { passive; } }
验证 OVSDB 配置是否正确。
user@MX4# show protocols ovsdb traceoptions { file ovsdb.log size 100m files 10; level all; flag all; } interfaces { xe-0/0/0.0; } controller 192.168.182.45 { protocol { ssl port 6632; } }
default-VS1
验证路由实例配置和网桥域。
user@MX4# show routing-instances default-VS1 vtep-source-interface lo0.0; instance-type virtual-switch; interface xe-0/0/0.1;
验证网桥域配置是否正确。
user@MX4# show bridge-domains 24a76aff-7e61-4520-a78d-3eca26ad7510 { vlan-id 3; vxlan { ovsdb-managed; vni 3; ingress-node-replication; } }
验证环路接口是否用作隧道源地址。
user@MX4# show switch-options vtep-source-interface lo0.0;