华为交换机M-LAG配置

2025-11-06 07:51:36

1、第一步【需求分析】

DS1和DS2、AS1和AS2交换机组建了多级M-LAG,DS1和DS2之间Eth-Trunk链路配置Peer-Link,交互M-LAG同步报文。在M-LAG设备之间配置V-STP破除环路。同时,在DS和CS设备上配置OSPF实现三层互通。

M-LAG配置要点:

以AS1和AS2组建M-LAG为例,DS设备配置类似。

2、第二步、在AS1和AS2上配置主接口的IP地址,且保证能够三层互通,专门用于M-LAG主备设备间心跳报文的传输。

<AS1> system-view

[~AS1] interface meth 0/0/0

[~AS1-MEth0/0/0] ip address 10.1.1.1 24

[*AS1-MEth0/0/0] quit

---------------------------------------------

<AS2> system-view

[~AS2] interface meth 0/0/0

[~AS2-MEth0/0/0] ip address 10.1.1.2 24

[*AS2-MEth0/0/0] quit

3、第三步、在AS1和AS2上配置M-LAG的DFS Group。

[*AS1] dfs-group 1

[*AS1-dfs-group-1] source ip 10.1.1.1

[*AS1-dfs-group-1] priority 150

[*AS1-dfs-group-1] quit

--------------------------------------------

[*AS2] dfs-group 1

[*AS2-dfs-group-1] source ip 10.1.1.2

[*AS2-dfs-group-1] priority 120

[*AS2-dfs-group-1] quit

4、第四步、在AS1和AS2上配置M-LAG的Peer-Link

[*AS1] interface eth-trunk 0

[*AS1-Eth-Trunk0] trunkport 10ge 1/0/3

[*AS1-Eth-Trunk0] trunkport 10ge 1/0/4

[*AS1-Eth-Trunk0] mode lacp-static

[*AS1-Eth-Trunk0] peer-link 1

[*AS1-Eth-Trunk0] quit

--------------------------------------------------

[*AS2] interface eth-trunk 0

[*AS2-Eth-Trunk0] trunkport 10ge 1/0/3

[*AS2-Eth-Trunk0] trunkport 10ge 1/0/4

[*AS2-Eth-Trunk0] mode lacp-static

[*AS2-Eth-Trunk0] peer-link 1

[*AS2-Eth-Trunk0] quit

5、第五步、在AS1和AS2上配置M-LAG的成员口

[*AS1] vlan batch 11

[*AS1] interface eth-trunk 20

[*AS1-Eth-Trunk20] mode lacp-static

[*AS1-Eth-Trunk20] port link-type trunk

[*AS1-Eth-Trunk20] port trunk allow-pass vlan 11

[*AS1-Eth-Trunk20] trunkport 10ge 1/0/1 to 1/0/2

[*AS1-Eth-Trunk20] dfs-group 1 m-lag 1

[*AS1-Eth-Trunk20] quit

[*AS1] interface eth-trunk 30

[*AS1-Eth-Trunk30] mode lacp-static

[*AS1-Eth-Trunk30] port link-type trunk

[*AS1-Eth-Trunk30] port trunk allow-pass vlan 11

[*AS1-Eth-Trunk30] trunkport 10ge 1/0/5 to 1/0/6

[*AS1-Eth-Trunk30] dfs-group 1 m-lag 2

[*AS1-Eth-Trunk30] quit

[*AS1] commit

--------------------------------------------------------------------

[*AS2] vlan batch 11

[*AS2] interface eth-trunk 20

[*AS2-Eth-Trunk20] mode lacp-static

[*AS2-Eth-Trunk20] port link-type trunk

[*AS2-Eth-Trunk20] port trunk allow-pass vlan 11

[*AS2-Eth-Trunk20] trunkport 10ge 1/0/1 to 1/0/2

[*AS2-Eth-Trunk20] dfs-group 1 m-lag 1

[*AS2-Eth-Trunk20] quit

[*AS2] interface eth-trunk 30

[*AS2-Eth-Trunk30] mode lacp-static

[*AS2-Eth-Trunk30] port link-type trunk

[*AS2-Eth-Trunk30] port trunk allow-pass vlan 11

[*AS2-Eth-Trunk30] trunkport 10ge 1/0/5 to 1/0/6

[*AS2-Eth-Trunk30] dfs-group 1 m-lag 2

[*AS2-Eth-Trunk30] quit

[*AS2] commit

声明:本网站引用、摘录或转载内容仅供网站访问者交流或参考,不代表本站立场,如存在版权或非法内容,请联系站长删除,联系邮箱:site.kefu@qq.com。
猜你喜欢