大家好,這裡是G-LAB IT實驗室。
⭕5月18日
CCNA+HCIA
新開班來啦
現在報名有早鳥價,感興趣的可咨詢
敲重點!
可小窗客服咨詢課程價格
v:glab-mary
本課程包含線下面授、線上直播、錄播、實驗、考試習題、輔導答疑、班級群及完善的教學服務。
以下是初級課程-華為生成樹實驗配置
01、實驗拓撲
02、實驗需求
1.按圖完成L2的鍊路捆綁
2.運作MSTP完成核心之間的負載分擔
3.按圖完成L3的鍊路捆綁
03、實驗步驟
A . L2的Etherchannel
SW1:
[SW1]vlan batch 10 20 30 40 (sw1上建立4個vlan)
[SW1]int Eth-Trunk 1 (建立鍊路聚合邏輯口)
[SW1-Eth-Trunk1]trunkport g0/0/1 (将實體接口加入邏輯接口)
[SW1-Eth-Trunk1]trunkport g0/0/2 (将實體接口加入邏輯接口)
[SW1-Eth-Trunk1]port link-type trunk (配置為trunk接口)
[SW1-Eth-Trunk1]port trunk allow-pass vlan all (透傳vlan)
[SW1]int Eth-Trunk 2 (建立鍊路聚合邏輯口)
[SW1-Eth-Trunk2]trunkport g0/0/3 (将實體接口加入邏輯接口)
[SW1-Eth-Trunk2]trunkport g0/0/4 (将實體接口加入邏輯接口)
[SW1-Eth-Trunk2]port link-type trunk (配置為trunk接口)
[SW1-Eth-Trunk2]port trunk allow-pass vlan all (透傳vlan)
SW2:
[SW2]vlan batch 10 20 30 40 (sw2上建立4個vlan)
[SW2]int Eth-Trunk 1 (建立鍊路聚合邏輯口)
[SW2-Eth-Trunk1]trunkport g0/0/1 (将實體接口加入邏輯接口)
[SW2-Eth-Trunk1]trunkport g0/0/2 (将實體接口加入邏輯接口)
[SW2-Eth-Trunk1]port link-type trunk (配置為trunk接口)
[SW2-Eth-Trunk1]port trunk allow-pass vlan all (透傳vlan)
[SW2]int Eth-Trunk 3 (建立鍊路聚合邏輯口)
[SW2-Eth-Trunk3]mode lacp-static (指定動态LACP模式)
[SW2-Eth-Trunk3]trunkport g0/0/3 (将實體接口加入邏輯接口)
[SW2-Eth-Trunk3]trunkport g0/0/4 (将實體接口加入邏輯接口)
[SW2-Eth-Trunk3]port link-type trunk (配置為trunk接口)
[SW2-Eth-Trunk3]port trunk allow-pass vlan all (透傳vlan)
SW3:
[SW3]vlan batch 10 20 30 40 (sw3上建立4個vlan)
[SW3]int Eth-Trunk 2 (建立鍊路聚合邏輯口)
[SW3-Eth-Trunk2]trunkport g0/0/1 (将實體接口加入邏輯接口)
[SW3-Eth-Trunk2]trunkport g0/0/2 (将實體接口加入邏輯接口)
[SW3-Eth-Trunk2]port link-type trunk (配置為trunk接口)
[SW3-Eth-Trunk2]port trunk allow-pass vlan all (透傳vlan)
[SW1]int Eth-Trunk 3 (建立鍊路聚合邏輯口)
[SW3-Eth-Trunk3]mode lacp-static (指定動态LACP模式)
[SW3-Eth-Trunk3]trunkport g0/0/3 (将實體接口加入邏輯接口)
[SW3-Eth-Trunk3]trunkport g0/0/4 (将實體接口加入邏輯接口)
[SW3-Eth-Trunk3]port link-type trunk (配置為trunk接口)
[SW3-Eth-Trunk3]port trunk allow-pass vlan all (透傳vlan)
三台交換機鍊路捆綁狀态均為up。
要注意的是兩條鍊路要能捆綁成功,必須滿足鍊路帶寬一緻,接口配置一緻。
B . MSTP
華為生成樹模式有三種:STP(工業标準);RSTP(工業标準);MST(工業标準)。預設模式是MST。其中STP和RSTP的特點是所有vlan一顆樹,是以無法實作負載分擔。
此時SW1上有ALTE口,證明SW1絕對不是根橋。
SW1:
[SW1]stp mode mstp (預設模式)
[SW1]stp region-configuration (進入mst配置模式)
[SW1-mst-region]region-name huawei(配置域名,必配且相同)
[SW1-mst-region]instance 1 vlan 10 30 (将vlan10,30關聯執行個體1)
[SW1-mst-region]instance 2 vlan 20 40 (将vlan20,40關聯執行個體2)
[SW1-mst-region]active region-configuration (激活配置)
[SW1]stp instance 1 root primary (設定SW1為執行個體1的主根橋)
[SW1]stp instance 2 root secondary
(設定SW1為執行個體2的備份根橋)
SW2:
[SW2]stp mode mstp (預設模式)
[SW2]stp region-configuration (進入mst配置模式)
[SW2-mst-region]region-name huawei(配置域名,必配且相同)
[SW2-mst-region]instance 1 vlan 10 30 (将vlan10,30關聯執行個體1)
[SW2-mst-region]instance 2 vlan 20 40 (将vlan20,40關聯執行個體2)
[SW2-mst-region]active region-configuration (激活配置)
[SW2]stp instance 1 root secondary
(設定SW1為執行個體1的備份根橋)
[SW2]stp instance 2 root primary(設定SW1為執行個體2的主根橋)
SW3:
[SW3]stp mode mstp (預設模式)
[SW3]stp region-configuration (進入mst配置模式)
[SW3-mst-region]region-name huawei(配置域名,必配且相同)
[SW3-mst-region]instance 1 vlan 10 30 (将vlan10,30關聯執行個體1)
[SW3-mst-region]instance 2 vlan 20 40 (将vlan20,40關聯執行個體2)
[SW3-mst-region]active region-configuration (激活配置)
此時SW1為執行個體1的主根橋,SW2為執行個體2的主根橋,進而實作了vlan間的負載
C . L3的鍊路捆綁
二層的鍊路捆綁主要是為了防環和增加帶寬,而三層的鍊路捆綁則是為了增加帶寬
華為的S5700交換機不支援将二層口修改為三層口。是以L2的鍊路捆綁和L3的鍊路捆綁基本是一樣的。
G-LAB IT實驗室課程