Port Aggregation Protocol (PAgP) also called EtherChannel is a Cisco proprietary protocol that is used for bundling two or more physical ports into single logical port. EtherChannel can provide high availability and increase bandwidth at the same time. There are three different methods to configure EtherChannel in Cisco switch. You can configure it manually or use protocols like PAgP or LACP. In production environment, you either use LACP or PAgP. In this post, I will show steps to Configure PAgP EtherChannel in Cisco IOS Switch.
Configure PAgP EtherChannel in Cisco IOS Switch
The physical switch ports in PAgP can be configured in one of two available modes in PAgP: –
- Auto – Passively waits for PAgP to form. If the remote switch port is configured with desirable then only it will form PAgP EtherChannel.
- Desirable – Actively tries to negotiate PAgP protocol with remote switch port. The remote switch port must be configured in Auto mode or Desirable mode to form PAgP EtherChannel.
The diagram below shows our simple network scenario. We have two Cisco switches, Switch-A and Switch-B connected with each other and have two links. Our goal is to bundle these two links into one logical link using PAgP protocol. The link is also a TRUNK port, so we need to configure EtherChannel and TRUNK in these ports.
Let’s configure PAgP in both Switches. Optionally you can shutdown physical ports before you start the configuration to avoid problems during the configuration. Also, better to remove existing configuration from physical interface because mismatch in configurations may not allow to form an EtherChannel. The configuration below is for Switch-A,
Switch-A(config)#interface range fastEthernet 0/1 - 2 Switch-A(config-if-range)#channel-group 1 mode desirable Switch-A(config-if-range)#channel-protocol pagp
The command channel-group 1 mode desirable means interface Fa0/1 and Fa0/2 will be member of logical interface port-channel 1 and ports Fa0/1 and Fa0/2 will actively try to negotiate to form EtherChannel using PAgP protocol. Do the same on Switch-B as shown below.
Switch-B(config)#interface range fastEthernet 0/1 - 2 Switch-B(config-if-range)#channel-group 1 mode desirable Switch-B(config-if-range)#channel-protocol pagp
Now, let’s verify EtherChannel port configuration. Let’s see on Switch-A,
Switch-A#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 port Number 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)
As we can see above, Port-channel group is 1, protocol being used is PAgP and ports that are member of Po1 are Fa0/1 and Fa0/2. You can also view the flags, Po1(SU) – S means the interface is working on layer 2, U means the port is in use. Also, in Fa0/1(P) – P means this port is member of port-channel.
Now, configure Port-Channel 1 as TRUNK port. Configure this on both Switches.
Switch-A(config)#int port-channel 1 Switch-A(config-if)#switchport trunk encapsulation dot1q Switch-A(config-if)#switchport mode trunk
When you configure something under port-channel interface as shown above, the configuration will automatically replicate under individual member physical interfaces as shown below. You should see running-configuration as shown below. This should be same on both switches.
interface FastEthernet0/1 channel-protocol pagp channel-group 1 mode desirable switchport mode trunk ! interface FastEthernet0/2 channel-protocol pagp channel-group 1 mode desirable switchport mode trunk
To verify if Port-Channel 1 is working as TRUNK, type show interface trunk command as shown below.
Switch-A#show int trunk Port Mode Encapsulation Status Native vlan Fa0/1 on 802.1q trunking 1 Fa0/2 on 802.1q trunking 1 Po1 on 802.1q trunking 1 Port Vlans allowed on trunk Fa0/1 1-1005 Fa0/2 1-1005 Po1 1-1005 Port Vlans allowed and active in management domain Fa0/1 1,10,20,30 Fa0/2 1,10,20,30 Po1 1,10,20,30 Port Vlans in spanning tree forwarding state and not pruned Fa0/1 1,10,20,30 Fa0/2 1,10,20,30 Po1 1,10,20,30
As you can see above, Fa0/1, Fa0/2 and Po1 are all TRUNK and in forwarding state. You can also view the spanning-tree information for VLAN 1 as shown below,
Switch-A#show spanning-tree VLAN0001 Spanning tree enabled protocol ieee Root ID Priority 32769 Address 0006.2AD3.33BA This bridge is the root Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Bridge ID Priority 32769 (priority 32768 sys-id-ext 1) Address 0006.2AD3.33BA Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Aging Time 20 Interface Role Sts Cost Prio.Nbr Type ---------------- ---- --- --------- -------- -------------------------------- Po1 Desg FWD 9 128.27 Shr
Notice, only port Po1 is in spanning tree and it is in forwarding state. Now traffic will be sent to Po1 not individual physical ports. PAgP will determine which port to send the traffic to based on the load balancing algorithm configured. To view the current load balancing method, type show etherchannel load-balance command as shown below. As of now, the load balancing is based on source MAC address as shown below.
Switch-A#show etherchannel load-balance EtherChannel Load-Balancing Configuration: src-mac EtherChannel Load-Balancing Addresses Used Per-Protocol: Non-IP: Source MAC address IPv4: Source MAC address IPv6: Source MAC address
To change the load balancing method you have various options as shown below. You can load balance based on destination IP, destination MAC address, source and destination IP, and so on. You can change the load balancing method from global configuration using port-channel load-balance command as shown below.
Switch-A(config)#port-channel load-balance ? dst-ip Dst IP Addr dst-mac Dst Mac Addr src-dst-ip Src XOR Dst IP Addr src-dst-mac Src XOR Dst Mac Addr src-ip Src IP Addr src-mac Src Mac Addr
In this way you can configure PAgP in Cisco Switches. You can also configure LACP protocol in Cisco switches for EtherChannel.
You may also like -
Latest posts by Bipin (see all)
- Why Backup your Microsoft Office 365 - November 27, 2020
- What’s New in VMware vSphere 7 - September 18, 2020
- Steps to Configure IP Address and Hostname in vSphere ESXi 7 - September 1, 2020