步骤:
配置堆叠
堆叠主:
switch 1 priority 15
copy run startup-config
reload slot 1
堆叠备:
switch 1 renumber2
switch 1priority 15
copy run startup-config
reload slot 1
连接堆叠线缆
配置端口聚合
interface Port-channel2
descriptionxxxx
switchport mode access
switchport accessvlan 10
划分接口:
interfaceGigabitEthernet1/0/2
switchportaccess vlan 10
switchportmode access
channel-group 2 mode active
interface GigabitEthernet2/0/2
switchport accessvlan 10
switchport modeaccess
channel-group 2 mode active
配置汇总:
Switch#showrun
Buildingconfiguration...
Currentconfiguration : 10270 bytes
!
!Last configuration change at 04:10:49 UTC Mon Jan 4 2016
!NVRAM config last updated at 04:05:07 UTC Mon Jan 4 2016
!
version15.0
noservice pad
servicetimestamps debug datetime msec
servicetimestamps log datetime msec
noservice password-encryption
!
hostnameSwitch
!
boot-start-marker
boot-end-marker
!
!
usernameshizhenning password 0 shizhenning51talk
noaaa new-model
switch1 provision ws-c2960x-24ts-l
switch2 provision ws-c2960x-24ts-l
!
!
noip domain-lookup
!
!
cryptopki trustpoint TP-self-signed-1172447744
enrollment selfsigned
subject-namecn=IOS-Self-Signed-Certificate-1172447744
revocation-check none
rsakeypair TP-self-signed-1172447744
!
!
cryptopki certificate chain TP-self-signed-1172447744
certificate self-signed 01
3082022B 30820194 A0030201 02020101 300D06092A864886 F70D0101 05050030
31312F30 2D060355 04031326 494F532D 53656C662D536967 6E65642D 43657274
69666963 6174652D 31313732 34343737 3434301E170D3136 30313034 30343035
30375A17 0D323030 31303130 30303030 305A3031312F302D 06035504 03132649
4F532D53 656C662D 5369676E 65642D43 6572746966696361 74652D31 31373234
34373734 3430819F 300D0609 2A864886 F70D010101050003 818D0030 81890281
8100C8CA 4C33B97D 13D21724 7F704484 5750F8C91130D905 1E54D8F6 DF0C3D6D
33A28F47 2618AC60 CB5C57E1 FAF38EB6 D2CA4B6E7EBCA73B FD165FEE 595FCB0F
0EE67C93 C15A6D14 B0F37FCC AC1C42CE C47A2FED4B5B4F6B 9693E601 406687E7
47B8C094 0428D80A 0D7A38A2 C1499A19 04445B0B1EF6DE18 A9ADAE96 44847975
72350203 010001A3 53305130 0F060355 1D130101 FF040530030101FF 301F0603
551D2304 18301680 1430AE4E 043C7D53 B55FC13B2459FACD CA56A8CF EB301D06
03551D0E 04160414 30AE4E04 3C7D53B5 5FC13B2459FACDCA 56A8CFEB 300D0609
2A864886 F70D0101 05050003 8181007F EB4F83A9E28D5775 9290BBF1 C1F789E4
CDE77125 4BC84C6A ECF36B80 81E37D4F 0C6C1CEED0BBFC80 7E518895 FACD9C9E
BFB1DADE 6B0FFD6E 1A8D6A10 F6553479 2DAAECC0F854E9F6 08FE0ADE D94ACD7F
7BB2C5C7 945379C0 D6D1BF60 70EDB5DE 02D84E133FCA85C2 6BC684C1 7141EEB8
FBF22FD0 B98B4F15 F87B181B 56F927
quit
spanning-treemode pvst
spanning-treeextend system-id
!
!
!
!
!
!
vlaninternal allocation policy ascending
!
!
!
!
!
!
interfacePort-channel1
description ConnectTo_IDC
switchport access vlan 10
switchport mode access
spanning-tree bpdufilter enable
!
interfacePort-channel2
description ConnectTo_Fortigate300D
switchport access vlan 10
switchport mode access
!
interfacePort-channel3
switchport access vlan 10
switchport mode access
!
interfacePort-channel4
switchport access vlan 10
switchport mode access
!
interfacePort-channel5
switchport access vlan 10
switchport mode access
!
interfacePort-channel6
switchport access vlan 10
switchport mode access
!
interfacePort-channel7
switchport access vlan 20
switchport mode access
!
interfacePort-channel8
switchport access vlan 20
switchport mode access
!
interfacePort-channel9
switchport access vlan 20
switchport mode access
!
interfacePort-channel10
switchport access vlan 20
switchport mode access
!
interfacePort-channel11
switchport access vlan 20
switchport mode access
!
interfacePort-channel12
switchport access vlan 20
switchport mode access
!
interfacePort-channel13
switchport access vlan 20
switchport mode access
!
interfacePort-channel14
switchport access vlan 20
switchport mode access
!
interfacePort-channel15
switchport access vlan 20
switchport mode access
!
interfacePort-channel16
switchport access vlan 20
switchport mode access
!
interfacePort-channel17
switchport access vlan 20
switchport mode access
!
interfacePort-channel18
switchport access vlan 20
switchport mode access
!
interfacePort-channel19
switchport access vlan 20
switchport mode access
!
interfacePort-channel20
switchport access vlan 20
switchport mode access
!
interfacePort-channel21
switchport access vlan 20
switchport mode access
!
interfacePort-channel22
switchport access vlan 20
switchport mode access
!
interfacePort-channel23
switchport access vlan 20
switchport mode access
!
interfacePort-channel24
switchport trunk allowed vlan 16
switchport mode trunk
!
interfaceFastEthernet0
no ip address
shutdown
!
interfaceGigabitEthernet1/0/1
switchport access vlan 10
spanning-tree bpdufilter enable
channel-group 1 mode active
!
interfaceGigabitEthernet1/0/2
switchport access vlan 10
switchport mode access
channel-group 2 mode active
!
interfaceGigabitEthernet1/0/3
switchport access vlan 10
switchport mode access
channel-group 3 mode active
!
interfaceGigabitEthernet1/0/4
switchport access vlan 10
switchport mode access
channel-group 4 mode active
!
interfaceGigabitEthernet1/0/5
switchport access vlan 10
switchport mode access
channel-group 5 mode active
!
interfaceGigabitEthernet1/0/6
switchport access vlan 10
switchport mode access
channel-group 6 mode active
!
interfaceGigabitEthernet1/0/7
switchport access vlan 20
switchport mode access
channel-group 7 mode active
!
interfaceGigabitEthernet1/0/8
switchport access vlan 20
switchport mode access
channel-group 8 mode active
!
interfaceGigabitEthernet1/0/9
switchport access vlan 20
switchport mode access
channel-group 9 mode active
!
interfaceGigabitEthernet1/0/10
switchport access vlan 20
switchport mode access
channel-group 10 mode active
!
interfaceGigabitEthernet1/0/11
switchport access vlan 20
switchport mode access
channel-group 11 mode active
!
interfaceGigabitEthernet1/0/12
switchport access vlan 20
switchport mode access
channel-group 12 mode active
!
interfaceGigabitEthernet1/0/13
switchport access vlan 20
switchport mode access
channel-group 13 mode active
!
interfaceGigabitEthernet1/0/14
switchport access vlan 20
switchport mode access
channel-group 14 mode active
!
interfaceGigabitEthernet1/0/15
switchport access vlan 20
switchport mode access
channel-group 15 mode active
!
interfaceGigabitEthernet1/0/16
switchport access vlan 20
switchport mode access
channel-group 16 mode active
!
interfaceGigabitEthernet1/0/17
switchport access vlan 20
switchport mode access
channel-group 17 mode active
!
interfaceGigabitEthernet1/0/18
switchport access vlan 20
switchport mode access
channel-group 18 mode active
!
interfaceGigabitEthernet1/0/19
switchport access vlan 20
switchport mode access
channel-group 19 mode active
!
interfaceGigabitEthernet1/0/20
switchport access vlan 20
switchport mode access
channel-group 20 mode active
!
interfaceGigabitEthernet1/0/21
switchport access vlan 20
switchport mode access
channel-group 21 mode active
!
interfaceGigabitEthernet1/0/22
switchport access vlan 20
switchport mode access
channel-group 22 mode active
!
interfaceGigabitEthernet1/0/23
switchport access vlan 20
switchport mode access
channel-group 23 mode active
!
interfaceGigabitEthernet1/0/24
switchport trunk allowed vlan 16
switchport mode trunk
channel-group 24 mode active
!
interfaceGigabitEthernet1/0/25
!
interfaceGigabitEthernet1/0/26
!
interfaceGigabitEthernet1/0/27
!
interfaceGigabitEthernet1/0/28
!
interfaceGigabitEthernet2/0/1
switchport access vlan 10
switchport mode access
spanning-tree bpdufilter enable
channel-group 1 mode active
!
interfaceGigabitEthernet2/0/2
switchport access vlan 10
switchport mode access
channel-group 2 mode active
!
interfaceGigabitEthernet2/0/3
switchport access vlan 10
switchport mode access
channel-group 3 mode active
!
interfaceGigabitEthernet2/0/4
switchport access vlan 10
switchport mode access
channel-group 4 mode active
!
interfaceGigabitEthernet2/0/5
switchport access vlan 10
switchport mode access
channel-group 5 mode active
!
interfaceGigabitEthernet2/0/6
switchport access vlan 10
switchport mode access
channel-group 6 mode active
!
interfaceGigabitEthernet2/0/7
switchport access vlan 20
switchport mode access
channel-group 7 mode active
!
interfaceGigabitEthernet2/0/8
switchport access vlan 20
switchport mode access
channel-group 8 mode active
!
interfaceGigabitEthernet2/0/9
switchport access vlan 20
switchport mode access
channel-group 9 mode active
!
interfaceGigabitEthernet2/0/10
switchport access vlan 20
switchport mode access
channel-group 10 mode active
!
interfaceGigabitEthernet2/0/11
switchport access vlan 20
switchport mode access
channel-group 11 mode active
!
interfaceGigabitEthernet2/0/12
switchport access vlan 20
switchport mode access
channel-group 12 mode active
!
interfaceGigabitEthernet2/0/13
switchport access vlan 20
switchport mode access
channel-group 13 mode active
!
interfaceGigabitEthernet2/0/14
switchport access vlan 20
switchport mode access
channel-group 14 mode active
!
interfaceGigabitEthernet2/0/15
switchport access vlan 20
switchport mode access
channel-group 15 mode active
!
interfaceGigabitEthernet2/0/16
switchport access vlan 20
switchport mode access
channel-group 16 mode active
!
interfaceGigabitEthernet2/0/17
switchport access vlan 20
switchport mode access
channel-group 17 mode active
!
interfaceGigabitEthernet2/0/18
switchport access vlan 20
switchport mode access
channel-group 18 mode active
!
interfaceGigabitEthernet2/0/19
switchport access vlan 20
switchport mode access
channel-group 19 mode active
!
interfaceGigabitEthernet2/0/20
switchport access vlan 20
switchport mode access
channel-group 20 mode active
!
interfaceGigabitEthernet2/0/21
switchport access vlan 20
switchport mode access
channel-group 21 mode active
!
interfaceGigabitEthernet2/0/22
switchport access vlan 20
switchport mode access
channel-group 22 mode active
!
interfaceGigabitEthernet2/0/23
switchport access vlan 20
switchport mode access
channel-group 23 mode active
!
interfaceGigabitEthernet2/0/24
switchport trunk allowed vlan 16
switchport mode trunk
channel-group 24 mode active
!
interfaceGigabitEthernet2/0/25
!
interfaceGigabitEthernet2/0/26
!
interfaceGigabitEthernet2/0/27
!
interfaceGigabitEthernet2/0/28
!
interfaceVlan1
ip address 172.18.0.254 255.255.255.0
!
ipdefault-gateway 172.18.0.1
iphttp server
iphttp secure-server
!
!
!
!
linecon 0
password 51talk.com
login
linevty 0 4
privilege level 15
login local
linevty 5 15
login
!
end