前言:

随着网络规模不断扩大,用户对骨干链路的带宽和可靠性提出了越来越高的要求。在传统技术中,常用更换高速率的接口板或更换支持高速率接口板的设备的方式来增加带宽,但这种方案需要付出高额的费用,而且不够灵活。

采用链路聚合技术可以在不进行硬件升级的条件下,通过将多个物理接口捆绑为一个逻辑接口,来达到增加链路带宽的目的。在实现增大带宽目的的同时,链路聚合采用备份链路的机制,可以有效的提高设备之间链路的可靠性。

链路聚合概述:

链路聚合又称以太网端口聚合(Aggregate-Port),是指在两台交换机之间,物理上将多个端口连接起来形成一个简单的逻辑端口,将多条链路聚合成一条逻辑链路。其中,这个逻辑端口被称为聚合端口(简称AP),可以增大链路带宽,解决交换网络中因带宽引起的网络瓶颈问题。多条物理链路之间能够相互冗余备份,其中任意一条链路断开,不会影响到其他链路正常转发数据。

链路聚合技术优点:

Eth-Trunk链路两端相连的物理接口的数量、速率、双工方式、流控方式必须一致。

实验:

华为交换机配置链路聚合(路由与交换技术)(1)

LSW1配置:(LSW1,LSW2配置一样。)

<Huawei>sys

[Huawei]undo in e

[Huawei]int e0/0/1

[Huawei-Ethernet0/0/1]undo negotiation auto--关闭自动协商

[Huawei-Ethernet0/0/1]duplex full---配置全双工方式

[Huawei-Ethernet0/0/1]speed 100---速率

Huawei-Ethernet0/0/1]q

[Huawei]int e0/0/2

[Huawei-Ethernet0/0/2]undo negotiation auto

[Huawei-Ethernet0/0/2]duplex full

[Huawei-Ethernet0/0/2]speed 100

Huawei-Ethernet0/0/2]q

[Huawei]int eth-trunk 1

[Huawei-Eth-Trunk1]int e0/0/1

[Huawei-Ethernet0/0/1]eth-trunk 1

[Huawei-Ethernet0/0/1]int e0/0/2

[Huawei-Ethernet0/0/2]eth-trunk 1

[Huawei-Ethernet0/0/2]q

[Huawei]int eth-trunk 1

[Huawei-Eth-Trunk1]load-balance ?---查看负载均衡的策略

dst-ip According to destination IP hash arithmetic

dst-mac According to destination MAC hash arithmetic

src-dst-ip According to source/destination IP hash arithmetic

src-dst-mac According to source/destination MAC hash arithmetic

src-ip According to source IP hash arithmetic

src-mac According to source MAC hash arithmetic

[Huawei-Eth-Trunk1]load-balance src-ip---设置负载均衡的策略,默认是S/D IP,LSW1和LSW2负载均衡策略一样

[Huawei-Eth-Trunk1]dis eth-trunk 1

Eth-Trunk1's state information is:

WorkingMode: NORMAL Hash arithmetic: According to SIP

Least Active-linknumber: 1 Max Bandwidth-affected-linknumber: 8

Operate status: up Number Of Up Port In Trunk: 2

--------------------------------------------------------------------------------

PortName Status Weight

Ethernet0/0/1 Up 1

Ethernet0/0/2 Up 1

测试:PC1pingPC2

华为交换机配置链路聚合(路由与交换技术)(2)

任意断开一条链路:

[Huawei]int e0/0/1

[Huawei-Ethernet0/0/1]shut

华为交换机配置链路聚合(路由与交换技术)(3)

再次PC1pingPC2

华为交换机配置链路聚合(路由与交换技术)(4)

可以看到仍然可以通信

,