03-14-2021 05:13 PM
Hello, I have a L3 switch on one end of the port-channel which is using 'src-dst-ip' as hashing algorithm and then a pure L2 switch on the opposite end using src-mac for it's port-channel hashing algorithm.
Is this OK, or should we be using the same algorithms on both ends ?
Thank you.
Solved! Go to Solution.
03-15-2021 08:48 AM
"Is this OK, or should we be using the same algorithms on both ends ?"
Maybe, maybe not.
For "optimal" load balancing/sharing, what you normally work toward is having the hashing attributes vary the most.
In ye olden times, Cisco switches had a limited choice of hashing attributes, often not more than using src-x or dst-x. When limited to such, depending on your topology, having different choices, per flow direction, could make a huge difference.
For example, consider a server interacting on one side of an Etherchannel with many hosts on the other side. If you were limited to src-mac and dst-mac, from server to hosts you wanted to use dst-mac. From hosts to server you wanted to use src-mac. Doing this, generally, provided a difference in a flow's attributes as used by the hashing algorithm.
On most Cisco switches, for some time now, many offer a src-dst-x. In a case like the prior example, that choice would work equally well from server to hosts or hosts to server.
That said, you might still have some special case where the optimal hashing attribute might not be obvious. So again, you need to understand your traffic flows, and select the best hashing option.
Do know, some times the Cisco switch doesn't provide a hashing option ideal for you. For example, between two hosts, MAC and IP are the same, so there will be no distribution of multiple flows, for those two hosts, across an Etherchannel. However, some of Cisco's higher end switches may provide an option to use source and destination UDP/TCP port numbers as part of the hash.
So again, having different hashing attributes on the two ends of a Etherchannel might be your optimal choice, especially depending on limitations of the switch platform.
BTW, src-dst-IP is often a good choice, when provided, in most situations. Using IP is often better than using MAC because it may deal better with traffic external to the local L2 domain.
03-14-2021 05:51 PM
Hi,
Yes, you can use different hashing algorithms on each side of the link if need be.
HTH
03-15-2021 03:56 AM
Not necessarly required to be same, but good to have consistance config, when you diagnosis the issues :
https://www.cisco.com/c/en/us/support/docs/lan-switching/etherchannel/12023-4.html
03-15-2021 08:48 AM
"Is this OK, or should we be using the same algorithms on both ends ?"
Maybe, maybe not.
For "optimal" load balancing/sharing, what you normally work toward is having the hashing attributes vary the most.
In ye olden times, Cisco switches had a limited choice of hashing attributes, often not more than using src-x or dst-x. When limited to such, depending on your topology, having different choices, per flow direction, could make a huge difference.
For example, consider a server interacting on one side of an Etherchannel with many hosts on the other side. If you were limited to src-mac and dst-mac, from server to hosts you wanted to use dst-mac. From hosts to server you wanted to use src-mac. Doing this, generally, provided a difference in a flow's attributes as used by the hashing algorithm.
On most Cisco switches, for some time now, many offer a src-dst-x. In a case like the prior example, that choice would work equally well from server to hosts or hosts to server.
That said, you might still have some special case where the optimal hashing attribute might not be obvious. So again, you need to understand your traffic flows, and select the best hashing option.
Do know, some times the Cisco switch doesn't provide a hashing option ideal for you. For example, between two hosts, MAC and IP are the same, so there will be no distribution of multiple flows, for those two hosts, across an Etherchannel. However, some of Cisco's higher end switches may provide an option to use source and destination UDP/TCP port numbers as part of the hash.
So again, having different hashing attributes on the two ends of a Etherchannel might be your optimal choice, especially depending on limitations of the switch platform.
BTW, src-dst-IP is often a good choice, when provided, in most situations. Using IP is often better than using MAC because it may deal better with traffic external to the local L2 domain.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide