跳转到内容
Ask AI

MC-LAG

此内容尚不支持你的语言。

Table 1 MC-LAG View

CommandPurpose
**show mclag state ** [domain-id]Display information about MC-LAG.
show mclag consistency_check_resultDisplay the results of the parameter consistency check of MC-LAG.
show interface errdownDisplay interfaces with err-down status.
**show loopback-detect ** [ethernet|link-aggregation interface_name]Display MC-LAG loopback detection configuration.

[Command] **show mclag state ** [domain-id]

[Purpose] Display information about MC-LAG.

[Parameters]

ParameterDescription
domain-idSpecify the domain ID, and the range is from 1 to 4095.

[View] Privileged User View

[Use Cases]

sonic# show mclag state 11
The MCLAG's keepalive is: OK
MCLAG info sync is: completed
Domain id: 11
Local Ip: 11.0.0.6
Peer Ip: 11.0.0.7
Peer Link Interface: Ethernet100
Keepalive time: 1
sesssion Timeout : 15
Peer Link Mac: 18:17:25:37:67:20
Role: Active
MCLAG Interface: PortChannel0009
Loglevel: NOTICE

[Command] show mclag consistency_check_result

[Purpose] Display the results of the parameter consistency check of MC-LAG.

[View] Privileged User View

[Use Cases]

sonic# show mclag consistency_check_result
---------------------------------------------------------------------------------
ifname mode(lacp/static) fast-rate fallback trunk_mode allowed_vlan
---------------------------------------------------------------------------------
lag203 Pass Pass Pass Pass Pass
lag202 Pass Pass Pass Pass Pass

[Command] show interface errdown

[Purpose] Display interfaces with err-down status.

[View] Privileged User View

[Use Cases]

sonic# show interface errdown
Interface Status
--------------- --------
Ethernet0 errdown
Ethernet1 up
Ethernet2 up
Ethernet3 up
Ethernet4 up
Ethernet5 up
Ethernet6 up
Ethernet7 up
Ethernet8 up
Ethernet9 up
Ethernet10 up
Ethernet11 up
Ethernet12 up
Ethernet13 up
Ethernet14 up
Ethernet15 up
Ethernet16 up
Ethernet17 up
Ethernet18 up
Ethernet19 up
Ethernet20 up
Ethernet21 up
Ethernet22 up
Ethernet23 up
Ethernet24 up
Ethernet25 up
Ethernet26 up
Ethernet27 up
Ethernet28 up
Ethernet29 up
Ethernet30 up
Ethernet31 up
Ethernet32 up
Ethernet33 up
Ethernet34 errdown
Ethernet35 up
Ethernet36 up
Ethernet37 up
Ethernet38 up
Ethernet39 up
Ethernet40 up
Ethernet41 up
Ethernet42 up
Ethernet43 up
Ethernet44 up
Ethernet45 up
Ethernet46 up
Ethernet47 errdown
Ethernet48 errdown
Ethernet52 up
Ethernet56 errdown
Ethernet60 errdown
Ethernet64 errdown
Ethernet68 up
Ethernet72 up
Ethernet76 up
PortChannel0001 errdown
PortChannel0099 up
Section titled “show loopback-detect [ethernet|link-aggregation”

[Command] **show loopback-detect ** [ethernet|link-aggregation interface_name]

[Purpose] Display MC-LAG loopback detection configuration.

[Parameters]

ParameterDescription
interface_nameInterface name (eg.0/1)

[View] Privileged User View

[Use Cases]

sonic# show loopback-detect
Port Policy Vlan Interval Wait time Vlans with loop
------ -------- ------- ---------- ----------- -----------------
lag111 shutdown 100-200 10 60
sonic# show loopback-detect link-aggregation 111
Port Policy Vlan Interval Wait time Vlans with loop
------ -------- ------- ---------- ----------- -----------------
lag111 shutdown 100-200 10 60

Table 2 MC-LAG Config

CommandPurpose
mclag domain domain-idCreate a MC-LAG domain.
peer-link {ethernet|link-aggregation} interface_nameSet peer-link for MC-LAG.
peer-address {A.B.C.D|A::B}Configure peer IP address of MC-LAG control link.
local-address {A.B.C.D|A::B}Configure local IP address of MC-LAG control link.
heartbeat-interval intervalSet the sending interval for MC-LAG keepalive messages.
session-timeout timeoutSet the timeout for MC-LAG sessions.
member lag lag-idConfigure the member ports for MC-LAG.
vrf vrf_nameSpecify the vrf that MC-LAG keepalive session belongs to.
consistency-check-action {default|graceful|idle}Specify the mode for MC-LAG consistency check.
backup-channel vlan vlan-idConfigure ICCP backup channel for MC-LAG.
dad local-address {A.B.C.D|A::B}Configure local IP address of MC-LAG DAD link.
dad peer-address {A.B.C.D|A::B}Configure peer IP address of MC-LAG DAD link.
dad detection-delay delay_timeSpecify the delay time for MC-LAG DAD detection.
dad recovery-delay {non-mlag|mlag} delay_timeSpecify the delay time for the interfaces in error-down to be brought up on MC-LAG standby side.
dad vrf vrf_nameSpecify the vrf where MC-LAG DAD link is located.
loopback-detect vlan vlan-id [policy {shutdown|block-vlan} interval interval [wait-time wait-time]]Configure MC-LAG loopback detection.
unique-ip vlan vlan-id [diff_mac|same_mac]Enable unique-ip feature for the VLAN.

Notes:

  • It is recommended to use low-speed interfaces for the member ports of MC-LAG. To improve system reliability, it is recommended to set the link aggregation mode of member ports to LACP, and it is also recommended to enable fast-rate to improve the performance of failover convergence.
  • Set a directly connected aggregation link between two MC-LAG peers as peer-link. It is recommended to use high-speed interfaces for peer-link. In order to improve the reliability of MC-LAG, it is recommended to set peer-link as static aggregation, and the number of member ports is no less than two. You need to manually assign a private VLAN for peer-link and add it to the service VLANs. No other configuration is allowed on the interfaces that are configured as peer-link.
  • It is recommended to use low-speed interfaces for DAD-link (currently does not support out-of-band Management Interface ). DAD-link and peer-link cannot be shared.
  • Please configure DAD-link when the peer-link status is up to prevent the ports of the standby side from being mistakenly set as error-down.
  • You need to manually set a monitor link group for MC-LAG active and standby side. The uplink port is configured as uplink, and the downlink port is configured as downlink, please refer to section Monitor Link Config for specific configuration commands.

[Command] mclag domain domain-id

[Purpose] Create a MC-LAG domain.

[Parameters]

ParameterDescription
domain-idSpecify the domain ID, and the range is from 1 to 4095.

[View] Global Configuration View

[Notes] Run command no mclag domain domain-id to delete MC-LAG domain.

[Use Cases]

sonic# configure terminal
sonic(config)# mclag domain 1

[Command] peer-link {ethernet|link-aggregation} interface_name

[Purpose] Set peer-link for MC-LAG.

[Parameters]

ParameterDescription
interface_nameInterface name (eg.0/1)

[View] MC-LAG Domain Configuration View

[Notes] Run command no peer-link to delete peer-link configuration.

[Use Cases]

sonic# configure terminal
sonic(config)# mclag domain 1
sonic(mclag-domain)# peer-link ethernet 0/100
sonic(mclag-domain)# peer-link link-aggregation 10

[Command] peer-address {A.B.C.D|A::B}

[Purpose] Configure peer IP address of MC-LAG control link.

[Parameters]

ParameterDescription
A.B.C.DIPv4 address
A::BIPv6 address

[View] MC-LAG Domain Configuration View

[Notes] Run command no peer-address to delete peer IP address of MC-LAG control link.

[Use Cases]

sonic# configure terminal
sonic(config)# mclag domain 1
sonic(mclag-domain)# peer-address 11.0.0.6

[Command] local-address {A.B.C.D|A::B}

[Purpose] Configure local IP address of MC-LAG control link.

[Parameters]

ParameterDescription
A.B.C.DIPv4 address
A::BIPv6 address

[View] MC-LAG Domain Configuration View

[Notes] Run command no local-address to delete local IP address of MC-LAG control link.

[Use Cases]

sonic# configure terminal
sonic(config)# mclag domain 1
sonic(mclag-domain)# local-address 11.0.0.6

[Command] heartbeat-interval interval

[Purpose] Set the sending interval for MC-LAG keepalive messages.

[Parameters]

ParameterDescription
intervalSpecify the interval in seconds. The range is from 1 to 60, and the default is 1.

[View] MC-LAG Domain Configuration View

[Notes] The keepalive message interval value should be less than 1/3 of the session timeout, and the session timeout should be a multiple of the keepalive message interval. Run command no heartbeat-interval to restore MC-LAG keepalive message sending interval to the default.

[Use Cases]

sonic# configure terminal
sonic(config)# mclag domain 1
sonic(mclag-domain)# heartbeat-interval 6

[Command] session-timeout timeout

[Purpose] Set the timeout for MC-LAG sessions.

[Parameters]

ParameterDescription
timeoutSpecify the timeout in seconds. The range is from 3 to 3600, and the default is 15.

[View] MC-LAG Domain Configuration View

[Notes] The keepalive message interval value should be less than 1/3 of the session timeout, and the session timeout should be a multiple of the keepalive message interval. Run command no session-timeout to restore MC-LAG session timeout to the default.

[Use Cases]

sonic# configure terminal
sonic(config)# mclag domain 1
sonic(mclag-domain)# session-timeout 6

[Command] member lag lag-id

[Purpose] Configure the member ports for MC-LAG.

[Parameters]

ParameterDescription
lag-idLAG ID, the range is from 1 to 9999.

[View] MC-LAG Domain Configuration View

[Notes] Supports configuring multiple MC-LAG member ports. Run command no member lag lag-id to delete MC-LAG member ports configuration.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# member lag 9

[Command] vrf vrf_name

[Purpose] Specify the vrf that MC-LAG keepalive session belongs to.

[Parameters]

ParameterDescription
vrf_nameSpecify the VRF name, the default VRF is default.

[View] MC-LAG Domain Configuration View

[Notes] Configure the vrf that MC-LAG keepalive session belongs to, that is, specify the vrf of the router interface to which local-address belongs. Run command no vrf to delete MC-LAG keepalive vrf configuration and restore to default vrf.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# vrf 9

consistency-check-action {default|graceful|idle}

Section titled “consistency-check-action {default|graceful|idle}”

[Command] consistency-check-action {default|graceful|idle}

[Purpose] Specify the mode for MC-LAG consistency check.

[Parameters]

ParameterDescription
defaultIn this mode, if the consistency check fails, the active and standby switches will bring the member ports down administratively at the same time.
gracefulIn this mode, if the consistency check fails, only standby switch will bring the member ports down administratively, and the active switch will keep the member ports up.
idleIn this mode, it only displays the result of the consistency check, without any corresponding action.

[View] MC-LAG Domain Configuration View

[Notes] The consistency check is in idle mode by default.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# consistency-check-action default

[Command] backup-channel vlan vlan-id

[Purpose] Configure ICCP backup channel for MC-LAG.

[Parameters]

ParameterDescription
vlan-idVLAN ID, the range is [1,4094].

[View] MC-LAG Domain Configuration View

[Notes] This feature requires an additional link. Add the interface to a separate VLAN and configure VLANIF with interface vlan vlan-id command, and then use this VLANIF as the ICCP backup channel. Run command no backup-channel to delete ICCP backup channel for MC-LAG.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# backup-channel vlan 10

[Command] dad local-address {A.B.C.D|A::B}

[Purpose] Configure local IP address of MC-LAG DAD link.

[Parameters]

ParameterDescription
A.B.C.DIPv4 address
A::BIPv6 address

[View] MC-LAG Domain Configuration View

[Notes] Run command no dad local-address to delete local IP address of MC-LAG DAD link.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# dad local-address 10.0.0.3

[Command] dad peer-address {A.B.C.D|A::B}

[Purpose] Configure peer IP address of MC-LAG DAD link.

[Parameters]

ParameterDescription
A.B.C.DIPv4 address
A::BIPv6 address

[View] MC-LAG Domain Configuration View

[Notes] Run command no dad peer-address to delete peer IP address of MC-LAG DAD link.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# dad peer-address 10.0.0.2

[Command] dad detection-delay delay_time

[Purpose] Specify the delay time for MC-LAG DAD detection.

[Parameters]

ParameterDescription
delay_timeSpecify the delay time in seconds. The range is from 0 to 512, and the default is 15.

[View] MC-LAG Domain Configuration View

[Notes] Run command no dad detection-delay time to restore the delay time to default.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# dad detection-delay 60

[Command] dad recovery-delay {non-mlag|mlag} delay_time

[Purpose] Specify the delay time for the interfaces in error-down to be brought up on MC-LAG standby side.

[Parameters]

ParameterDescription
non-mlagConfigure the delay time for non-MC-LAG members.
mlagConfigure the delay time for MC-LAG members.
delay_timeSpecify the delay time for error-down interface state recovery in seconds. The range is from 0 to 1000. The default value is 60 for MC-LAG members and 0 for non-MC-LAG members.

[View] MC-LAG Domain Configuration View

[Notes] Run command no dad recovery-delay {non-mlag|mlag} to restore the delay time to default.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# dad recovery-delay non-mlag 30
sonic(mclag-domain)# dad recovery-delay mlag 90

[Command] dad vrf vrf_name

[Purpose] Specify the vrf where MC-LAG DAD link is located.

[Parameters]

ParameterDescription
vrf_nameSpecify the VRF name, the default VRF is default.

[View] MC-LAG Domain Configuration View

[Notes] Run command no dad vrf to restore the VRF of MC-LAG DAD link to default VRF.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# dad vrf 200

[Command] loopback-detect vlan vlan-id [policy {shutdown|block-vlan} interval interval [wait-time wait-time]]

[Purpose] Configure MC-LAG loopback detection.

[Parameters]

ParameterDescription
vlan-idVLAN ID, the range is [1,4094].
policyOptionally configure the execution policy after a loopback has been detected. The default is shutdown mode.
shutdownIndicates that the switch will shut down interfaces with loopback detection configured.
block-vlanIndicates that the switch will block the VLAN with loopback detection configured.
intervalSpecify the interval time in seconds, and the default value is 5 seconds.
wait-timeSpecifies the wait time in seconds before restoring a blocked port or VLAN. The default value is 60 seconds.

[View] Physical Interface Configuration View / LAGIF Configuration View

[Notes] This feature is enabled on the MC-LAG downlink aggregation port to avoid traffic looping due to configuration mistakes. Run command no loopback-detect to disable loopback detection.

[Use Cases]

sonic# configure
sonic(config)# interface ethernet 0/52
sonic(config-if-0/52)# loopback-detect vlan 10 policy shutdown interval 3
sonic(config)# interface link-aggregation 111
sonic(config-lagif-111)# loopback-detect vlan 200-300

[Command] unique-ip vlan vlan-id [diff_mac|same_mac] [Purpose] Enable unique-ip feature for the VLAN.

[Parameters]

ParameterDescription
vlan-idVLAN ID, the range is [1,4094].
diff_macUse diff_mac mode when the MAC of the MC-LAG Peer’s protocol VLAN is different and the default is diff-mac mode when not specified.
same_macUse same_mac mode when the MAC of the MC-LAG Peer’s protocol VLAN is the same.

[View] MC-LAG Domain Configuration View

[Notes] This feature supports the MC-LAG Peer to establish a routing protocol with the access side to transmit routes. There are two programmes currently supported:

  1. The gateway VLAN and the routing protocol VLAN are shared. The primary IP of the SVI are supposed to be different for protocol interactions, while the secondary IP be the same for external gateway. The VLAN MAC should be set to the same value (not the same with system MAC or interface MAC of the peers). In addition, it is required to enable unique-ip in same_mac mode and ARP proxy in EVPN mode for this VLAN.
  2. Dual VLANs, that is, the gateway VLAN is separate from the routing protocol VLAN. The IP and the MAC of the gateway VLAN should be the same. While the IP of the routing protocol VLAN should be different from one another and the MAC can just use the default value. In addition, it is required to enable unique-ip in diff_mac mode and ARP proxy in EVPN mode for routing protocol VLAN. Run command no unique-ip vlan vlan-id to disable unique-ip for vlan.

[Use Cases]

sonic# configure
sonic(config)# mclag domain 1
sonic(mclag-domain)# unique-ip vlan 3010 same_mac