标签:
Objective
Background
Four switches have just been installed. The distribution layer switches are Catalyst 3560 switches, and the access layer switches are Catalyst 2960 switches. There are redundant uplinks between the access layer and distribution layer. Usually, only one of these links could be used; otherwise, a bridging loop might occur. However, using only one link utilizes only half of the available bandwidth. EtherChannel allows up to eight redundant links to be bundled together into one logical link. In this lab, you configure Port Aggregation Protocol (PAgP), a Cisco EtherChannel protocol, and Link Aggregation Control Protocol (LACP), an IEEE 802.3ad open standard version of EtherChannel.
Step 1: Prepare the switches for the lab.
Delete vlan.dat, erase the startup configuration, and reload all your switches.
Step 2: Configure basic switch parameters
Note: If the ports are configured with dynamic auto mode and you do not set the mode of the ports to trunk, the links do not form trunks and remain access ports. The default mode on a 3560 or 2960 switch is dynamic auto. The default mode on a 3550 or 2950 switch is dynamic desirable.
DLS1 example:
DLS1# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
DLS1(config)# interface range fastEthernet 0/7 - 12
DLS1(config-if-range)# switchport trunk encapsulation dot1q
DLS1(config-if-range)# switchport mode trunk
Step 3: Configure an EtherChannel with Cisco PAgP.
Note: When configuring EtherChannels, it is a recommended best practice to shutdown the physical ports being grouped on both devices before configuring them into channel groups. Otherwise, the EtherChannel Misconfig Guard may place these ports into err-disabled state. The ports and port channel can be re-enabled after the EtherChannel is configured.
ALS1(config)# interface range fastEthernet 0/11 - 12
ALS1(config-if-range)# channel-group 1 mode desirable
Creating a port-channel interface Port-channel 1
ALS1(config)# interface port-channel 1
ALS1(config-if)# switchport mode trunk
The show interfaces trunk and show spanning-tree commands also show the port channel as one logical link.
Step 4: Configure an 802.3ad LACP EtherChannel.
ALS1(config)# interface range fastEthernet 0/7 - 8
ALS1(config-if-range)# channel-group 2 mode active
Creating a port-channel interface Port-channel 2
ALS1(config-if-range)# interface port-channel 2
ALS1(config-if)# switchport mode trunk
Step 5: Configure a Layer 3 EtherChannel.
In the previous steps, you configured EtherChannels as Layer 2 trunk connections between switches. You can also configure EtherChannels as Layer 3 (routed) connections on switches that support routed ports. Because DLS1 and DLS2 are both multilayer switches, they can support routed ports.
DLS1(config)# interface range fastEthernet 0/11 - 12
DLS1(config-if-range)# no switchport
DLS1(config-if-range)# channel-group 3 mode desirable
Creating a port-channel interface Port-channel 3
DLS1(config-if-range)# interface port-channel 3
DLS1(config-if)# no switchport
DLS1(config-if)# ip address 10.0.0.1 255.255.255.0
Step 6: Configure load balancing.
The switches can use different methods to load-balance traffic going through a port channel. The available methods as well as the default method used varies by hardware platform. By default, Cisco Catalyst 3560 and Catalyst 2960 switches load-balance using the source MAC address.
Other methods of load balancing are based on the destination MAC address, both source and destination MAC addresses, source IP address, destination IP address, and both source and destination IP addresses. Some older platforms, such as the Cisco Catalyst 2950 and Catalyst 3550 switches, may not support all of these methods.
ALS1(config)# port-channel load-balance src-dst-mac
Challenge
The topology still has redundant links that you can aggregate. Experiment with the other port channel modes using the question mark on the interface-level command channel-group number mode ?. Look at the descriptions and implement some port channels in different ways. If The port mode is set to desirable, auto, active or passive (when PAgP or LACP are used), the command channel-protocol can be used. It cannot be used with channel-group number mode on command. The “on” mode statically sets the EtherChannel protocol without negotiation.
标签:
原文地址:http://www.cnblogs.com/elewei/p/5148623.html