华为交换机静态LACP汇聚设置
- 网络拓扑结构:

- 实现过程:
将两台交换机3个端口汇聚到一个组,实现增加网络带宽及提高可靠性、负载分担的目的,具体配置如下Switch-A
system-view //进入到管理模式
[HUAWEI] sysname SwitchA //将交换机名称更改为SwitchA
[SwitchA] vlan 100 //添加vlan100
[SwitchA] int vlan100 //进入到vlanif100
[SwitchA] ip address 192.168.1.1 255.255.255.0 //设置vlanIP及掩码
[SwitchA-Eth-Trunk1] quit //退出vlan设置
[SwitchA] interface eth-trunk 1 //创建交换机汇聚组eth-trunk 1
[SwitchA-Eth-Trunk1] trunkport gigabitethernet 0/0/1 to 0/0/3 //将交换机端口1-3加入到这个汇聚组
[SwitchA-Eth-Trunk1] mode lacp-static //设置LACP为静态模式。
[SwitchA-Eth-Trunk1] max active-linknumber 2 //更改活动接口数阈值位1,默认为8。
[SwitchA-Eth-Trunk1] port link-type trunk //将端口组设置为trunk模式
[SwitchA-Eth-Trunk1] port trunk allow-pass vlan 100 //允许端口组通过vlan100的数据流
[SwitchA-Eth-Trunk1] quit //退出端口组配置
[SwitchA]interface GigabitEthernet 0/0/24 //进入到我们电脑连接的24号端口
[SwitchA-GigabitEthernet0/0/24] port link-type access //设置该端口为access模式
[SwitchA-GigabitEthernet0/0/24] port default vlan 100 //设置该端口Vlan为100
[SwitchA-Eth-Trunk1] quit //退出接口配置
Switch-B
system-view //进入到管理模式
[HUAWEI] sysname SwitchB //将交换机名称更改为SwitchB
[SwitchB] vlan 100 //添加vlan100
[SwitchB] interface eth-trunk 1 //创建交换机汇聚组eth-trunk 1
[SwitchB-Eth-Trunk1] trunkport gigabitethernet 0/0/1 to 0/0/3 //将交换机端口1-3加入到这个汇聚组
[SwitchB-Eth-Trunk1] mode lacp-static //设置LACP为静态模式。
[SwitchB-Eth-Trunk1] max active-linknumber 2 //更改活动接口数阈值位1,默认为8。
[SwitchB-Eth-Trunk1] port link-type trunk //将端口组设置为trunk模式
[SwitchB-Eth-Trunk1] port trunk allow-pass vlan 100 //允许端口组通过vlan100的数据流
[SwitchB-Eth-Trunk1] quit //退出端口组配置
[SwitchB]interface GigabitEthernet 0/0/24 //进入到我们电脑连接的24号端口
[SwitchB-GigabitEthernet0/0/24] port link-type access //设置该端口为access模式
[SwitchB-GigabitEthernet0/0/24] port default vlan 100 //设置该端口Vlan为100
[SwitchB-Eth-Trunk1] quit //退出接口配置
我们可以通过`dis eth-trunk 1`命令来查看端口汇聚组的一个工作状态判断网络是否通畅我们可以使用PC1和PC2两台主机进行互ping,具体看数据流的方式推荐使用Wireshark来进行抓包分析.判以上就是华为交换机配置静态LACP的方式,如果有错误的地方请在下方留言,我将及时的改正~!

































