H3C交換機端口鏈路聚合
以太網鏈路聚合 -- 以太網鏈路聚合配置命令 -- lacp system-priority
lacp system-priority命令用來配置系統的LACP優先級。
undo lacp system-priority命令用來恢復缺省情況。
【命令】
lacp system-priority system-priority
undo lacp system-priority
【缺省情況】
系統的LACP優先級為32768。
【視圖】
系統視圖
【缺省用戶角色】
network-admin
mdc-admin
【參數】
system-priority:系統的LACP優先級,取值范圍為0~65535。該數值越小,優先級越高。
【舉例】
# 配置系統的LACP優先級為64。
<Sysname> system-view
[Sysname] lacp system-priority 64
【相關命令】
link-aggregation port-priorityH3C交換機端口鏈路聚合
交換機配置:
交換機4個光口中,交換機18和20號端口連接測試儀10/1和10/2端口,交換機此兩個端口進行綁定端口聚合,交換機22和24號端口連接被測試設備10/1和10/2端口,交換機此兩個端口綁定端口聚合。
交換機配置命令:
< HUAWEI >sys //全局配置模式
[HUAWEI]mode lacp //啟用lacp模式
【Eth-Trunk 1】連接測試儀端口
[HUAWEI]interface Eth-Trunk 1 //創建Eth-Trunk 1, 為綁定18和20號端口
[HUAWEI]interface XGigabitEthernet 0/0/18 //進入18端口配置
[HUAWEI]lacp priority 100 //18號口lacp優先級
[HUAWEI] Eth-Trunk 1 //18號口綁定Eth-Trunk
[HUAWEI]interface XGigabitEthernet 0/0/20 //進入20端口配置
[HUAWEI]lacp priority 100 //20號口lacp優先級
[HUAWEI] Eth-Trunk 1 //20號口綁定Eth-Trunk
【Eth-Trunk 2】連接被測設備端口
[HUAWEI]interface Eth-Trunk 2 //創建Eth-Trunk 1, 為綁定22和24號端口
[HUAWEI]interface XGigabitEthernet 0/0/22 //進入22端口配置
[HUAWEI]lacp priority 100 //22號口設置lacp優先級
[HUAWEI] Eth-Trunk 2 //22號口綁定Eth-Trunk
[HUAWEI]interface XGigabitEthernet 0/0/24 //進入24端口配置
[HUAWEI]lacp priority 100 //24號口lacp優先級
[HUAWEI] Eth-Trunk 2 //24號口綁定Eth-Trunk



LACP概述
LACP(Link Aggregation Control Protocol)鏈路聚合技術,提高了Trunk的容錯性。靜態鏈路聚合能夠對Trunk內鏈路端口按照全雙工/高速率、全雙工/低速率、半雙工/高速率、半雙工/低速率的優先次序進行調度,確保trunk內各個鏈路的負載均衡。
對接組網

Switch的0/0/1、0/0/2、0/0/3三個端口組成trunk,分別與ADC的1/1、1/2、1/3連接,ADC上業務網段所在VLAN ID為2300。下面將以此組網進行配置。
配置交換機
1. 配置交換機Trunk
<SwitchA> system-view
[SwitchA] interface eth-trunk 1
[SwitchA-Eth-Trunk1] port link-type trunk
[SwitchA-Eth-Trunk1] undo port trunk allow-pass vlan 1
[SwitchA-Eth-Trunk1] port trunk allow-pass vlan 2300
[SwitchA-Eth-Trunk1] bpdu enable
[SwitchA-Eth-Trunk1] mode lacp-static
[SwitchA-Eth-Trunk1] quit
2. 將接口加入Trunk
[SwitchA] interface gigabitethernet 0/0/1
[SwitchA-GigabitEthernet0/0/1] eth-trunk 1
[SwitchA-GigabitEthernet0/0/1] quit
[SwitchA] interface gigabitethernet 0/0/2
[SwitchA-GigabitEthernet0/0/2] eth-trunk 1
[SwitchA-GigabitEthernet0/0/2] quit
[SwitchA] interface gigabitethernet 0/0/3
[SwitchA-GigabitEthernet0/0/3] eth-trunk 1
[SwitchA-GigabitEthernet0/0/3] quit
3. 保存配置
[SwitchA] quit
<SwitchA>save
4. 配置ADC
1. 通過SSH登錄到ADC命令行窗口
2. 運行下面的命令,配置指定接口為LACP模式此處lacpKey為接口所屬的LA channel的編號,可以取1-4的整數,比如我們取值為1
set lacp -sysPriority 1 // 默認值為 32768
set interface 1/1 –lacpMode ACTIVE –lacpKey 1 -tagall OFF
set interface 1/2 –lacpMode ACTIVE –lacpKey 1 -tagall OFF
set interface 1/3 –lacpMode ACTIVE –lacpKey 1 -tagall OFF
3. 配置LA channel
set channel LA/1 -state ENABLED –tagall OFF
4. 添加VLAN ID,此處VLAN ID為ADC上業務網段的VLAN ID,前面已經假定為2300
add vlan 2300
5. 綁定vlan到LA channel
bind vlan 2300 –ifnum LA/1 -tagged
6. 保存配置
save ns config
