Showing posts with label Switching. Show all posts
Showing posts with label Switching. Show all posts

Friday, February 6, 2015

Aggregation, Load Balancing, and Redundancy

EtherChannel has numerous advantages, the most probable being bandwidth aggregation. Learn EtherChannel aggregation techniques including PAgP and LACP as defined by Cisco and IEEE 802.3ad. Compare methods used to include load balancing and redundancy techniques on physical switches and connecting to the virtual data center. Explore configuration examples which include both Layer 2 and Layer 3 connectivity. Participants will demonstrate basic EtherChannel concepts using a Packet Tracer activity. Second place GIR Contest regional winner United States and Canada.

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

EtherChannel: Aggregation, Load Balancing, and Redundancy 

Topology Diagram

EtherChannel: Aggregation, Load Balancing, and Redundancy

Addressing Table:

Host
Interface
Address
MLS1
G0/1
172.16.1.1/30

VLAN 10
192.168.10.1/24

VLAN 20
192.168.20.1/24
R1
G0/1
172.16.1.2/30

G0/0.20
192.168.30.1/24
G0/0.30
192.168.30.1/24
PC1-V10
Ethernet
192.168.10.5
PC2-V10
Ethernet
192.168.10.6
PC3-V20
Ethernet
192.168.20.5
PC4-V20
Ethernet
192.168.20.6
PC5-V10
Ethernet
192.168.10.7
PC6-V10
Ethernet
192.168.10.8
PC7-V20
Ethernet
192.168.20.7
PC8-V20
Ethernet
192.168.20.8
PC10-V30
Ethernet
192.168.30.5
PC11-V30
Ethernet
192.168.30.6
PC12-V40
Ethernet
192.168.40.5
PC13-V40
Ethernet
192.168.40.6

In this lab all PCs have been assigned their associated IP addresses as static.  Instructors may decide to add appropriate requirements to enable a DHCP server with helper-addresses on router interfaces or use DHCP services on the layer 3 devices.

Introduction:


When a switched network spans multiple switches, a method of linking those switches must be used.  A Fast Ethernet, Gigabit Ethernet or 10Gigabit Ethernet port can be used to uplink between switches, but this introduces a bottleneck to the flow of traffic.  To demonstrate try using a 24-port 2960 switch having 23 Fast Ethernet ports sending traffic over a single Fast Ethernet link to another switch. 
Unfortunately when we connect two or more ports from one switch to another spanning-tree will place one port into blocking state to protect against a layer 2 loop. 
The initial configuration of this lab could vary depending on the instructors intended use.  This Packet Tracer file could be used to present a number of switching related topics: VLANs, Trunking, VTP, InterVLAN routing, and EtherChannel.
Review the address design.  In an effort to save time for this demonstration the PCs have been configured with appropriate addresses and default gateways.  The following tasks/objectives will need to be performed:
  • Enable each switch as VTP Transparent Mode
  • Create the proper VLANs on each Transparent mode switch
  • Create Trunks for each port interconnecting switches
  • Create Etherchannels to aggregate trunks between switches
  • Confirm or configure load-balance method for Etherchannels
  • Troubleshoot if needed

Part 1 Prepare the switches

Step 1. Enable each switch as VTP Transparent Mode
SW1(config)#vtp mode transparent
Setting device to VTP TRANSPARENT mode
Step 2.  Create Appropriate VLANs on each switch.
SW1(config)#vlan 10
SW1(config-vlan)#vlan 20
SW1(config-vlan)#exit
Repeat for each switch – MLS1, SW2,  Create VLAN 30, 40 on SW3, SW4

Step 3. Assign Access VLANs to the appropriate ports on each switch
SW1(config)#int range fa0/5 - 6
SW1(config-if-range)#switchport mode access
SW1(config-if-range)#switchport access vlan 10
SW1(config-if-range)#spanning-tree portfast
%Warning: portfast should only be enabled on ports connected to a single
 host. Connecting hubs, concentrators, switches, bridges, etc... to this
 interface  when portfast is enabled, can cause temporary bridging loops.
 Use with CAUTION

%Portfast will be configured in 2 interfaces due to the range command
 but will only have effect when the interfaces are in a non-trunking mode

Repeat for fa0/7 – 8 and assign vlan 20, complete the same task on SW2.  On SW3 assign fa0/5 – 6 vlan 30 and on SW4 assign fa0/5 – 6 vlan 40

Step 4. Create Trunk links between switches
MLS1(config)#int range fa0/1 – 4
MLS1(config-if-range)#switchport trunk encap dot1q
MLS1(config-if-range)#switchport mode trunk
SW1(config-if-range)#int range fa0/1 – 2
SW1(config-if-range)#switchport mode trunk
SW2(config-if-range)#int range fa0/3 – 4
SW2(config-if-range)#switchport mode trunk

Now test the default spanning-tree results:  output may vary!
SW2#sho spanning-tree vlan 1
VLAN0001
  Spanning tree enabled protocol ieee
  Root ID    Priority    32769
             Address     000A.4139.EE2E
             Cost        19
             Port        3(FastEthernet0/3)
             Hello Time  2 sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32769  (priority 32768 sys-id-ext 1)
             Address     000C.8511.C2C9
             Hello Time  2 sec  Max Age 20 sec  Forward Delay 15 sec
             Aging Time  20

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Fa0/3            Root FWD 19        128.3    P2p
Fa0/4            Altn BLK 19          128.4    P2p

PART 2 Create Etherchannels

Step 1:  Use PAgP for etherchannel between MLS1 and SW1
MLS1(config)#int range fa0/1 – 2
MLS1(config-if-range)#channel-protocol pagp
MLS1(config-if-range)#channel-group 1 mode desirable
MLS1(config-if-range)#
Creating a port-channel interface Port-channel 1
SW1(config)#int range fa0/1 – 2
SW1(config-if-range)#channel-protocol pagp
SW1(config-if-range)#channel-group 1 mode auto
SW1(config-if-range)#
Creating a port-channel interface Port-channel 1
Step 2:  Use LACP for etherchannel between MLS1 and SW2
MLS1(config)#interface range fa0/3 – 4
MLS1(config-if-range)#channel-protocol lacp
MLS1(config-if-range)#channel-group 2 mode active
MLS1(config-if-range)#
Creating a port-channel interface Port-channel 2
SW2(config)#int range fa0/3 – 4
SW2(config-if-range)#channel-protocol lacp
SW2(config-if-range)#channel-group 2 mode passive
SW2(config-if-range)#
Creating a port-channel interface Port-channel 2
Step 3.  Use manual ON for etherchannel between SW3 and SW4.
SW3(config)#int range fa0/1 – 2
SW3(config-if-range)#channel-group 3 mode on
SW3(config-if-range)#
Creating a port-channel interface Port-channel
SW4(config-if-range)#channel-group 3 mode on
SW4(config-if-range)#
Creating a port-channel interface Port-channel 3
Step 4.  Take another look at spanning-tree and verify the port-channel interfaces have the least cost path and there are no ports in blocking state.  This is an indication that all uplink ports are in use.  Check each switch.  Output may vary.
SW2#show spanning-tree
.
.
VLAN0010
  Spanning tree enabled protocol ieee
  Root ID    Priority    32778
             Address     000A.4139.EE2E
             Cost        9
             Port        27(Port-channel 2)
             Hello Time  2 sec  Max Age 20 sec  Forward Delay 15 sec

  Bridge ID  Priority    32778  (priority 32768 sys-id-ext 10)
             Address     000C.8511.C2C9
             Hello Time  2 sec  Max Age 20 sec  Forward Delay 15 sec
             Aging Time  20

Interface        Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
Fa0/5            Desg FWD 19        128.5    P2p
Fa0/6            Desg FWD 19        128.6    P2p
Po2              Root FWD 9         128.27   Shr
Step 5.  Verify that EtherChannel is working.
SW2#sho 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 port
Number of channel-groups in use: 1
Number of aggregators:           1

Group  Port-channel  Protocol    Ports
---------+------------------+-------------+----------------------------------------------
2            Po2(SU)          LACP           Fa0/3(P)   Fa0/4(P)


Note:  if the EtherChannel does not come up, you might want to try shutting down the physical interfaces on both ends of the EtherChannel.  Using the “shut” , “no shut” commands. 
Also use:
MLS1#sho interface trunk
Port        Mode         Encapsulation  Status        Native vlan
Po1         on             802.1q               trunking      1
Po2         on             802.1q               trunking      1

Port        Vlans allowed on trunk
Po1         1-1005
Po2         1-1005

Port        Vlans allowed and active in management domain
Po1         1,10,20
Po2         1,10,20

Port        Vlans in spanning tree forwarding state and not pruned
Po1         1,10,20
Po2         1,10,20
Use the “show etherchannel port-channel command to verify aggregation state and protocol
MLS1#sho etherchannel port-channel
                Channel-group listing:
                ----------------------
Group: 1
----------
                Port-channels in the group:
                ---------------------------
Port-channel: Po1
-----------
Age of the Port-channel   = 00d:00h:40m:16s
Logical slot/port   = 2/1       Number of ports = 2
GC                  = 0x00000000      HotStandBy port = null
Port state          = Port-channel
Protocol            =   PAGP
Port Security       = Disabled

Ports in the Port-channel:

Index   Load   Port     EC state        No of bits
------+-------------+----------+-------------------+-----------
  0         00      Fa0/2    Active             0
  0         00      Fa0/1    Active             0
Time since last port bundled:    00d:00h:38m:02s    Fa0/1



Part 3 Load Balancing

Step 1:  Check the default load balance method used
SW1#sho etherchannel load-balance
EtherChannel Load-Balancing Operational State (src-mac):
Non-IP: Source MAC address
  IPv4: Source MAC address
  Ipv6: Source MAC address
Step 2:  Change the load-balance method to src-dst-ip
SW1(config)#port-channel load-balance src-dst-ip
SW1#sho etherchannel load-balance
EtherChannel Load-Balancing Operational State (src-dst-ip):
Non-IP: Source XOR Destination MAC address
  IPv4: Source XOR Destination IP address
  IPv6: Source XOR Destination IP address
Note:  Packet Tracer currently lacks support for fully testing load –balance with the following command I have placed it here for reference that could be used on live physical switches to test the load balance algorithm.
SWA# test etherchannel load-balance interface port-channel number {ip|mac} [source ip] [destination ip]
Would select Fa0/2 of Po1

Part 4 Configure the Intervlan routing

Step 1:  Turn on routing for the MLS1 switch
MLS1(config)#ip routing
MLS1(config)#int g0/1
MLS1(config-if)#no switchport
MLS1(config-if)#ip add 172.16.1.1 255.255.255.252
MLS1(config-if)#interface vlan 10
MLS1(config-if)#ip address 192.168.10.1 255.255.255.0
MLS1(config-if)#interface vlan 20
MLS1(config-if)#ip address 192.168.20.1 255.255.255.0
MLS1(config)#ip route 192.168.30.0 255.255.255.0 172.16.1.2
MLS1(config)#ip route 192.168.40.0 255.255.255.0 172.16.1.2
Step 2:  Configure R1 with intervlan routing (Router-on-a-stick)
SW4(config)#interface g1/1
SW4(config-if)#switchport mode trunk 
R1(config)#interface g0/0
R1(config-if)#no shutdown
R1(config-if)#interface g0/0.30
R1(config-subif)#encapsulation dot1q 30
R1(config-subif)#ip address 192.168.30.1 255.255.255.0
R1(config-subif)#interface g0/0.40
R1(config-subif)#encapsulation dot1q 40
R1(config-subif)#ip address 192.168.40.1 255.255.255.0
R1(config)#interface g0/1
R1(config-if)#ip address 172.16.1.2 255.255.255.252
R1(config-if)#no shutdown
R1(config)#ip route 192.168.10.0 255.255.255.0 172.16.1.1
R1(config)#ip route 192.168.20.0 255.255.255.0 172.16.1.1
Test successful pings from PC1-V10 to PC7-V20, PC10-V30, and PC12-V40.  All pings should respond successfully.  Otherwise troubleshoot appropriate etherchannel, trunks, and intervlan routing.