简单组网(Eth-Trunk)负载分担链路聚合

两台交换机上有vlan101和vlan102的网络,两台交换机之间采用Eth-Trunk模式,实现链路聚合负载分担。

1、拓扑图

image

2、创建vlan,并将接口加入到vlan中

SWA

复制代码
[swa]vlan batch 101 102
Info: This operation may take a few seconds. Please wait for a moment...done.
[swa]int e0/0/1
[swa-Ethernet0/0/1]port link-type access
[swa-Ethernet0/0/1]port default vlan 101
[swa-Ethernet0/0/1]int e0/0/2
[swa-Ethernet0/0/2]port link-type access
[swa-Ethernet0/0/2]port default vlan 102
[swa-Ethernet0/0/2]quit
复制代码

SWB

复制代码
[swb]vlan batch 101 102
Info: This operation may take a few seconds. Please wait for a moment...done.
[swb]int e0/0/1
[swb-Ethernet0/0/1]port link-type access
[swb-Ethernet0/0/1]port default vlan 101
[swb-Ethernet0/0/1]int e0/0/2
[swb-Ethernet0/0/2]port link-type access
[swb-Ethernet0/0/2]port default vlan 102
[swb-Ethernet0/0/2]quit
复制代码

3、创建Eth-Trunk接口,并将成员加入进来,同时将接口设置为trunk模式,允许vlan101和vlan102通过

SWA

[swa]int Eth-Trunk 1
[swa-Eth-Trunk1]trunkport GigabitEthernet 0/0/1 to 0/0/2
Info: This operation may take a few seconds. Please wait for a moment...done.
[swa-Eth-Trunk1]port link-type trunk
[swa-Eth-Trunk1]port trunk allow-pass vlan 101 102

SWB

[swb]int Eth-Trunk 1
[swb-Eth-Trunk1]trunkport GigabitEthernet 0/0/1 to 0/0/2
Info: This operation may take a few seconds. Please wait for a moment...done.
[swb-Eth-Trunk1]port link-type trunk
[swb-Eth-Trunk1]port trunk allow-pass vlan 101 102

4、配置Eth-Trunk1的负载均衡分担方式

SWA

[swa]int Eth-Trunk 1
[swa-Eth-Trunk1]load-balance src-dst-mac
[swa-Eth-Trunk1]quit
[swa]

SWB

[swb]int Eth-Trunk 1
[swb-Eth-Trunk1]load-balance src-dst-mac
[swb-Eth-Trunk1]quit
[swb]

5、测试

使用PC3 ping 1.1.1.2 -t,然后SWA进入g0/0/1或者g0/0/2接口,shutdown。连通性中断,一段时间后恢复正常。

6、负载分担方式

复制代码
dst-ip 根据目的IP哈希算法

dst-mac 根据目的地MAC哈希算法

src-dst-ip 根据源/目的IP哈希算法

src-dst-mac 根据源/目标MAC哈希算法

src-ip 根据源IP哈希算法

src-mac 根据源MAC哈希算法
复制代码


读书和健身总有一个在路上

posted @   Renqy  阅读(2251)  评论(1编辑  收藏  举报
编辑推荐:
· 10年+ .NET Coder 心语,封装的思维:从隐藏、稳定开始理解其本质意义
· .NET Core 中如何实现缓存的预热?
· 从 HTTP 原因短语缺失研究 HTTP/2 和 HTTP/3 的设计差异
· AI与.NET技术实操系列:向量存储与相似性搜索在 .NET 中的实现
· 基于Microsoft.Extensions.AI核心库实现RAG应用
阅读排行:
· 10年+ .NET Coder 心语 ── 封装的思维:从隐藏、稳定开始理解其本质意义
· 地球OL攻略 —— 某应届生求职总结
· 提示词工程——AI应用必不可少的技术
· Open-Sora 2.0 重磅开源!
· 周边上新:园子的第一款马克杯温暖上架
点击右上角即可分享
微信分享提示