• Advertisement

LACP - Hashing Algorithms

VTP, Portfast, Spanning Tree and all the other switch related stuff.

LACP - Hashing Algorithms

Postby Guest » Sat Jan 01, 2011 8:23 am

Hi all,

 

I am looking for some help regarding LACP, and in particular its associated hashing algorithms.  I realise there are algorithms based on source/destination MAC and source/destination IP which seem pretty understandable for Layer 2 and Layer 3.  However, it is the underlying algorithm that load balances that traffic type that I would like to understand in greater detail.

 

Example

 

If I used LACP for a server and aggregated 4 NICs at gigabit speeds within a Layer 2 switch, how would traffic destined to and from that server be load balanced?  It is the XOR operation that I am particularly confused about.  As an example, if the server 192.168.1.1 was talking to another server (192.168.1.46) a 2-Bit XOR would be used.  Converting the IP addresses to binary would mean 001 (1) and 110 (6) i think.  The 4 NIC etherchannel would mean a 2 BIT XOR and therefore would mean the 01 and 10 would be used to create an index of 11.  So i believe that would mean Link 3 would be used?  Im guessing therefore, that traffic to and from these IP Addresses would always use Link 3 of the channel.

 

What im looking for here is to better understand when i would need to change the algorithm to load balance traffic more effectively; and also if LACP is even worthwhile being used for server purposes outside of Virtualisation. 

 

Would the default algorithm be suitable in a single server environment where multiple desktops connect to a single server?

 

Hope this makes sense!

 

Thanks

 

Nick

Guest
 

Advertisement

Re:LACP - Hashing Algorithms

Postby Guest » Sat Jan 01, 2011 9:27 am

Nick,

 

You e correct in that its entirely possible to have arrangements wherein some of the links in the port-channel are never actually used.  The trick to getting full use of the port-channel is knowing what the traffic is going to be and chosing the correct load-balancing algorithm.  In the 6500s for example (and other devices as well, I imagine) there is also an option to factor in the TCP port to try to get a more even mix.  As you pointed out, if the XOR comes to the same result every time, the traffic will go over the same link everytime since that XOR result is used a look-up into the physical links.  A mechanism that may work is to assign a secondary IP to the server, one IP being even, the other being odd and having the server round-robin the IPs when sending traffic.  Just a thought, your mileage may vary.

Guest
 

Re:LACP - Hashing Algorithms

Postby Guest » Sat Jan 01, 2011 10:29 am

Thanks for the response Philip; I guess im over complicating things.  With gigabit connectivity would there really be a requirement for a server to operate at greater speeds.  For example, would a domain controller really require anything greater than 1Gbps.  I can understand the requirement for Virtualisation where you may be pushing large amounts of traffic through the adapter, but for application servers is this really a necessity?

 

Can you suggest a good tool or feature that would adequately confirm bandwidth passing through a servers adapter over a defined period.  Would something like PRTG perform this type of monitoring?

Guest
 

Re:LACP - Hashing Algorithms

Postby Guest » Sat Jan 01, 2011 10:57 am

> but for application servers is this really a necessity?

 

There are probably some uses where it is - if your application happens to be media-heavy and has to talk to a SAN or something.  At a certain point it makes more sense to throw a 10G NIC into the server than use a port-channel.  When you have a port-channel it kind of becomes like a bank office (at least here in the states); just because you have six windows, doesn mean there are six people being helped.  When you have a 10G pipe, you actually get 10G of bandwidth (more or less) but when you have say, a 4G port-channel you can count on 4G of bandwidth necessarily.

 

Im not a server expert, but you may want to look into LACP modes, and how they can be implemented on your server.  Its my understanding that a server can be set to at least send its traffic over the links in sequence (mode 4, if Im remembering correctly).  That wouldn necessarily help with return traffic to the server, but you may be able to get a more even distribution out from the server.

 

>Can you suggest a good tool or feature[clip]

 

I personally can , no.  Depending on your control/knowledge with regard to the server, you may be able to make that call yourself (eg, the server is always talking to the same two IPs, so use src-dst-ip).  Im sure theres something out there that will help with that but Im unaware of anything.

Guest
 

Re:LACP - Hashing Algorithms

Postby Guest » Sat Jan 01, 2011 12:18 pm

Thanks for your help Philip it has been greatly received.

 

Ill rate the post now for you.

Guest
 



  • Advertisement


Similar topics

802.3ad - LACP configuration on 6500
Forum: Cisco Switching
Author: Anonymous
Replies: 7

Where can I get the LACP MIB?
Forum: Network Management
Author: Anonymous
Replies: 0

SF300 LAG port doesn work, LACP will not enable.
Forum: Small Business Switches
Author: Anonymous
Replies: 0

2960 LACP and VLan Issues
Forum: Cisco Switching
Author: Anonymous
Replies: 0

LACP support on Nexus 2000 with Nexus 7000 as parent switch
Forum: Cisco Switching
Author: Anonymous
Replies: 0


Return to Cisco Switching

Who is online

Users browsing this forum: No registered users and 3 guests