EVPN LAG 配置优秀实践
QFX 系列交换机上的 Junos OS 支持企业样式配置和服务提供商样式配置。
这两种配置样式都可用于配置 EVPN LAG。我们建议使用 Enterprise 配置样式,因为它支持更多数据中心功能,如风暴控制配置文件和 BPDU 阻止,而无需在叶设备上启用 RSTP。
本节介绍同时使用这两种配置样式的 EVPN LAG 配置。
使用企业配置样式的 CRB 架构的 EVPN LAG 配置
在大多数数据中心架构中,推荐使用企业配置样式来启用 EVPN LAG 功能。企业样式配置通常比服务提供商样式配置简单,并且通常与其他第 2 层功能更兼容。
以下配置提供了一个使用集中路由桥接架构中叶设备上的企业配置样式完成的 EVPN LAG 配置示例。
user@leaf_node1>show configuration interfaces ae0 esi { 00:33:33:33:33:33:33:33:33:01; a unique but same value at leafs connected to given server all-active; } aggregated-ether-options { lacp { active; system-id 00:33:33:33:33:01; a unique but same value at leafs connected to given server } } unit 0 { family ethernet-switching { interface-mode trunk; vlan { members [ 100-101 ]; the explicit vlan-ids enabled with vxlan - can’t be mixed with regular vlans on same ESI-LAG } } } user@leaf_node1> show configuration vlans vlan100 { vlan-id 100; value provisioned at the ESI-LAG interface in enterprise-mode vxlan { vni 50100; } } vlan101 { vlan-id 101; vxlan { vni 50101; } } user@leaf_node1> show configuration interfaces et-0/0/50 description esi-lag-member-link; ether-options { 802.3ad ae0; } user@leaf_node1> show configuration switch-options vtep-source-interface lo0.0; lo0.0 must be in the global routing table route-distinguisher 1.1.1.21:1; RD must be a unique value per leaf vrf-import MY-FABRIC-IMPORT; vrf-target target:1:5555; root@dc-tme-qfx5110-1> show configuration protocols evpn vni-options { vni 10001 { vrf-target target:1:100; } vni 10002 { vrf-target target:1:101; } } encapsulation vxlan; multicast-mode ingress-replication; default-gateway do-not-advertise; extended-vni-list [ 50100 50101 ]; user@leaf_node1> show configuration policy-options policy-statement MY-FABRIC-IMPORT term term1 { from community MY-FAB-COMMUNITY; then accept; } term term2 { from community COM-VNI-50100; then accept; } term term3 { from community COM-VNI-50101; then accept; } then reject; user@leaf_node1> show configuration policy-options community MY-FAB-COMMUNITY members target:1:5555; user@leaf_node1> show configuration policy-options policy-statement LB { term term1 { from protocol evpn; then { load-balance per-packet; } } term term2 { then { load-balance per-packet; } } } policy-statement MY-FABRIC-IMPORT { term term1 { from community MY-FAB-COMMUNITY; then accept; } term term2 { from community ESI-SPINE; then accept; } term term3 { from community COM-VNI-50100; then accept; } term term4 { from community COM-VNI-50101; then accept; } then reject; } policy-statement MY_VTEPS { term term1 { from { route-filter 1.1.1.0/24 prefix-length-range /32-/32; } then accept; } then reject; } community COM-VNI-50100 members target:1:100; community COM-VNI-50101 members target:1:101; community MY-FAB-COMMUNITY members target:1:5555; community SPINE-ESI members target:1:8888; user@leaf_node1> show configuration protocols bgp log-updown; group overlay { type internal; local-address 1.1.1.21; family evpn { signaling; } vpn-apply-export; local-as 64512; bfd-liveness-detection { minimum-interval 300; multiplier 3; } multipath; neighbor 1.1.1.11; neighbor 1.1.1.12; } group underlay { type external; export MY_VTEPS; multipath multiple-as; neighbor 10.10.19.1 { peer-as 65511; } neighbor 10.10.21.1 { peer-as 65512; } } user@leaf_node1> show configuration interfaces et-0/0/48 description spine0_connected; mtu 9216; unit 0 { family inet { address 10.10.19.2/24; } } user@leaf_node1> show configuration interfaces et-0/0/49 description spine1_connected; mtu 9216; unit 0 { family inet { address 10.10.21.2/24; } }
使用服务提供商配置样式的 CRB 架构的 EVPN LAG 配置
QFX5110交换机还支持服务提供商风格的配置。以服务提供商配置样式配置 EVPN LAG 时,会为每个给定的 EVPN LAG 分配多个单元。这些多个单元提供了对每个单元接口进行更具选择性的过滤器和速率限制的机会,但这些分配必须按单元进行,因此配置和维护工作很繁重。在使用主干和叶拓扑的数据中心架构中,通常不需要这种细粒度,因此,在大多数数据中心环境中启用 EVPN LAG 时,我们不建议使用服务提供商样式配置。
以下配置提供了使用服务提供商配置样式完成的 EVPN LAG 配置示例。当QFX5110或QFX5120交换机在 IRB 不在叶设备(即集中路由桥接 (CRB) 和桥接叠加 (BO) 架构)中以叶设备角色运行时,支持此配置。当QFX5110或QFX5120交换机用作边缘路由桥接 (ERB) 架构中的叶设备时,企业配置样式必须用于启用 EVPN LAG。
user@leaf_node1> show configuration interfaces ae11 flexible-vlan-tagging; encapsulation extended-vlan-bridge; esi { 00:33:33:33:33:33:33:33:33:01; all-active; } aggregated-ether-options { lacp { active; periodic fast; system-id 00:33:33:33:33:01; } } unit 100 { vlan-id 100; } unit 101 { vlan-id 101; } <- Corresponding VxLAN - > VLAN Mapping user@leaf_node1> show configuration vlans vlan100 interface ae11.100; vxlan { vni 50100; } {master:0} user@leaf_node1> show configuration vlans vlan101 interface ae11.101; vxlan { vni 50101; }