提示:文章写完后,目录可以自动生成,如何生成可参考右边的帮助文档
目录
三、实验拓扑
一、实验环境
EVE-NG社区懒人版4.2
二、实验使用的设备
三、实验拓扑
四.实验脚本
S1
enable
configure terminal
no ip domain-lookup
no logging on
hostname S1
vlan 1
vlan 2
vlan 3
vlan 4
exit
default interface range GigabitEthernet0/0-1
lacp system-priority 100
interface GigabitEthernet 0/0
channel-protocol lacp
channel-group 1 mode active
lacp port-priority 1313
switchport trunk encapsulation dot1q
switchport mode trunk
exit
interface GigabitEthernet 0/1
channel-protocol lacp
channel-group 1 mode active
lacp port-priority 1414
switchport trunk encapsulation dot1q
switchport mode trunk
end
write
copy running-config startup-config
S2
enable
configure terminal
no ip domain-lookup
no logging on
Hostname S2
vlan 1
vlan 2
vlan 3
vlan 4
exit
default interface range GigabitEthernet 0/0-1
lacp system-priority 200
interface range GigabitEthernet 0/0-1
channel-protocol lacp
channel-group 1 mode passive
lacp port-priority 1313
switchport trunk encapsulation dot1q
switchport mode trunk
exit
end
write
copy running-config startup-config
五.命令输入过程
S1
S2
六.命令含义
1.配置S1交换机
2.配置S2交换机
技术要点:
①交换机激活某端口的LACP 协议后,该端口将通过发送LACPDU向对端通告自己的系统优先级、系统MAC地址、端口优先级和端口号。对端接收到这些信息后,将这些信息与自己的属性比较,选择能够聚合的端口,从而双方可以对端口加入或退出某个动态聚合组达成一致。
②由于交换机每个 EtherChannel组所能支持的最大端口数有限制,如果当前的成员端口数量超过了可聚合的最大端口数的限制,则本端系统和对端系统会进行协商,根据交换机LACP系统ID来决定端口的状态,LACP系统ID小的一方为主动端。在主动端首先比较LACP端口优先级,端口优先级小的端口被选中,如果 LACP端口优先级相同,则比较端口号,端口号小的被选中并加入 EtherChannel组。
七.验证LACP协商EtherChannel
1.show etherchannel summary
以上输出表明EtherChannel协商成功,协商协议为LACP。注意应在链路的两端都进行检查,确认两端都形成端口通道才行,SU表示EtherChannel正常工作。
2.show etherchannel protocol
以上输出显示了交换机S2的LACP邻居S1的信息,其中,在 Flags字段中,SA中的S表示设备采用慢速(Slow)发送LACP数据包,A表示LACP的模式为Active。LACP发送消息的频率可以配置为每隔1秒钟或者30秒钟发送一个LACP数据包,这两种发送频率都是由IEEE 802.3ad标准所规定的。配置为 Fast,对端发送LACP消息的周期为1秒;配置为 Slow,对端发送LACP消息的周期为30秒。本实验平台的3560交换机不支持Fast方式(65系列交换机支持),端口下配置的命令为lacp rate fast。LACP协议消息的超时时间为LACP消息发送周期的3倍。两端配置的超时时间可以不一致。但为了便于维护,建议用户配置一致的LCAP协议消息超时时间。以上输出还显示了通过本交换机端口连接的邻居端口的LACP端口优先级、设备ID、老化时间、管理Key、操作Key、端口号和端口状态。