端口/链路聚合
端口聚合(Aggregate-port)又称链路聚合,是指两台交换机之间在物理上将多个端口连接起来,将多条链路聚合成一条逻辑链路。从而增大链路带宽,解决交换网络中因带宽引起的网络瓶颈问题。多条物理链路之间能够相互冗余备份,其中任意一条链路断开,不会影响其他链路的正常转发数据。
switch0
Switch>en
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
#关闭生成树协议
Switch(config)#no spanning-tree vlan 1
#创建链路聚合组
Switch(config)#interface port-channel 1
#选择端口
Switch(config-if)#interface range fa 0/21-24
#开启链路聚合
Switch(config-if-range)#channel-group 1 mode on
Switch(config-if-range)#
%LINK-5-CHANGED: Interface Port-channel1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Port-channel1, changed state to up
Switch(config-if-range)#end
Switch#
%SYS-5-CONFIG_I: Configured from console by console
#查看配置
Switch#show runni
Switch#show running-config
Building configuration...
Current configuration : 1282 bytes
!
version 15.0
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Switch
!
!
!
!
!
!
no spanning-tree vlan 1
spanning-tree mode pvst
spanning-tree extend system-id
!
interface Port-channel1
!
interface FastEthernet0/1
.........
!
interface FastEthernet0/21
channel-group 1 mode on
!
interface FastEthernet0/22
channel-group 1 mode on
!
interface FastEthernet0/23
channel-group 1 mode on
!
interface FastEthernet0/24
channel-group 1 mode on
!
interface GigabitEthernet0/1
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
switch1
Switch>en
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#no s
Switch(config)#no sp
Switch(config)#no spanning-tree vlan 1
Switch(config)#interface port-channel 1
Switch(config-if)#int range fa 0/21-24
Switch(config-if-range)#channel-group 1 mode on
Switch(config-if-range)#
%LINK-5-CHANGED: Interface Port-channel1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Port-channel1, changed state to up
Switch(config-if-range)#ex
Switch(config)#ex
Switch#
%SYS-5-CONFIG_I: Configured from console by console
Switch#show runn
Switch#show running-config
Building configuration...
Current configuration : 1230 bytes
!
version 15.0
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Switch
!
!
!
!
!
!
no spanning-tree vlan 1
spanning-tree mode pvst
spanning-tree extend system-id
!
interface Port-channel1
!
interface FastEthernet0/1
!
......
interface FastEthernet0/21
channel-group 1 mode on
!
interface FastEthernet0/22
channel-group 1 mode on
!
interface FastEthernet0/23
channel-group 1 mode on
!
interface FastEthernet0/24
channel-group 1 mode on
!
interface GigabitEthernet0/1
!
interface GigabitEthernet0/2
!
!
!
!
!
end