链路聚合:增加带宽(作用)、提供备份(作用)。
链路聚合的配置:
[huewei ] lacp priorty 10000 ###########配置系统LACP优先级
[huewei ] int eth-teunk 1 ######进入eth-trunk试图
[huewei-eth-trunk1] bpdu enable #######配置接口上发送到BPDU报文到cpu处理,起到防环作用
[huewei-eth-trunk1] mode lacp-static #############配置eth-trunk为静态LACP模式
[huewei] int e0/0/11
[huewei-int e0/0/11]enth-trunk 1
[huewei] int e0/0/12
[huewei]int e0/0/12]enth-trunk 1
[huewei]dis enth-trunk 1 ###########下面有三个成员此时三个口是跑流量 的负载冗余
[huewei 】int enth-trunk 1
[huewei - enth-trunk 1] max active-linknumber 2
###配置链路聚合活动接口数上限阈值。剩余的成员的接口处于备份状态,未配置上限阈值则Eth-Trunk最多允许8个接口同时处于活动状态。
[huewei - enth-trunk 1]dis this
配置trunk
[sw1]int Eth-Trunk 1
[sw1]int Eth-Trunk 1]port link-type trunk
[sw1]int Eth-Trunk 1]port trunk allow-pass vlan all
[sw2]int Eth-Truk 1
[sw2]int Eth-Truk 1]port link-type trunk
[sw2]int Eth-Truk 1]port link-type trunk
[sw2]int Eth-Truk 1]port trunk allow-pass vlan all
交换机2配置
[huawe]int Eth-trunk 1
[huawe]int Eth-trunk 1]bpdu enable
[huawe]int Eth-trunk 1]mode lacp-static
[huawei]int e0/0/11
[huawei-int e/0/0/11]enth-trunk 1
[huawei]int e0/0/12
[huawei-int e/0/0/11]enth-trunk 1
[huawei ]interface enth-trunk 1
[huawei-eth-trunk 1] trunkport ethernet0/0/10 to 0/0/12 ######向Eth-Trunk批量增加成员接口
[huawei]dis eth-trunk1
#####负载冗余测试###
down 掉其中的一条链路
[huawei]dis trunkmemberdhip eth-trunk1 ######查看链路负载情况
<huawei>system-view