Etherchannel 分为二层和三层etherchannel
以太网链路捆绑用来增加带宽和负载均衡。拓扑如下: SW1的配置: interface FastEthernet0/1 channel-group 1 mode desirable switchport mode trunk interface FastEthernet0/2 channel-group 1 mode desirable switchport mode trunk interface Port-channel 1 switchport mode trunk SW2的配置: interface FastEthernet0/1 channel-group 1 mode desirable switchport mode trunk interface FastEthernet0/2 channel-group 1 mode desirable switchport mode trunk interface Port-channel 1 switchport mode trunk show etherchannel summary 查看以太网通道的状态 SW2#show etherchannel summary Flags: D - down P - in port-channel I - stand-alone s - suspended H - Hot-standby (LACP only) R - Layer3 S - Layer2 U - in use f - failed to allocate aggregator u - unsuitable for bundling w - waiting to be aggregated d - default portNumber of channel-groups in use: 1
Number of aggregators: 1 Group Port-channel Protocol Ports ------+-------------+-----------+---------------------------------------------- 1 Po1(SU) PAgP Fa0/1(P) Fa0/2(P) S代表的是二层以太网通道 U代表UP 通道起来了 P代表这两个接口参与了以太网通道 注意的是:逻辑接口的配置会覆盖物理接口上的配置 这样就看到效果了吧! 另外要注意以太网通道的模式 etherchannel 的模式: 1、PAGP的模式: on:不进行协商,没有协商traffic。类似nonegotiate auto:passive negotiat state。可接受对端发出的协商,但不会主动申请。(默认) desirable:active negotiat state。主动协商状态。主动发送PAGP包。 2、LACP的模式: passive:passive negotiating state。被动状态,可接受。但不会主动申请(默认) active:active negotiating state。主动状态,主动申请。 注意: on on OK desirable desirable OK desirable auto OK auto auto 形成不了 auto on 形成不了 active active OK passive active OK passive passive 形成不了