VMware Cloud Community
sbeaver
Leadership
Leadership
Jump to solution

Network Load Balance

I'm actually stuck on this one here... Does anyone know what the

heck the difference is between "Virtual Port Based" and "MAC Based" load

balancing ACTUALLY is? I cannot find ANY VMware documentation that says

anything other than "Based off virtual port ID" or "Based off MAC hash"

for either. By the nature of a virtual switch, every virtual NIC that

is created by assigning it to a virtual machine has a unique MAC address

and is given a virtual port from the virtual switch. Virtual ports are

not created unless a virtual NIC (including VMkernel, Console virtual

NICs) are assigned to a virtual switch through a port group...So, by

this relationship, there is no logically difference between a MAC

address and a virtual port...so what is the difference in these options?

Is the "Virtual Port Based" round robin, whereas MAC is an actual Hash?

Nothing comes out and actually says this that I can find.

Points for the brain of the day!!!

Steve Beaver
VMware Communities User Moderator
VMware vExpert 2009 - 2020
VMware NSX vExpert - 2019 - 2020
====
Co-Author of "VMware ESX Essentials in the Virtual Data Center"
(ISBN:1420070274) from Auerbach
Come check out my blog: [www.virtualizationpractice.com/blog|http://www.virtualizationpractice.com/blog/]
Come follow me on twitter http://www.twitter.com/sbeaver

**The Cloud is a journey, not a project.**
Reply
0 Kudos
1 Solution

Accepted Solutions
RParker
Immortal
Immortal
Jump to solution

With source-MAC address forwarding, when packets are forwarded to an EtherChannel, the packets are distributed across the ports in the channel based on the source-MAC address of the incoming packet. Therefore, to provide load balancing, packets from different hosts use different ports in the channel, but packets from the same host use the same port in the channel. With destination-MAC address forwarding, when packets are forwarded to an EtherChannel, the packets are distributed across the ports in the channel based on the destination host MAC address of the incoming packet. Therefore, packets to the same destination are forwarded over the same port, and packets to a different destination are sent on a different port in the channel

______________________________________________

Technically MAC based load balancing is usual done at the hardware level. Since in ESX BOTH are controlled by the OS, there isn't much difference in overhead.

It's just setup to make it comfortable for those that KNOW the differnce. Since Virtual Ports are controlled by VI, I would think that Virtual Port would be LESS overhead than that of a MAC, since the system would have to take into account the MAC, and thus route based on incoming/outgoing traffice and analyze the origin and destination. Virtual Ports are natural, but MAC base are additional layer.

If you already had a Cisco switch with MAC based, you could offload the switch to the ESX server, and simply use the same settings. I would think that Vmware knowing all of this info, incorporated MAC based for compatibility, and if there are network engineers that want to use ESX, it would be easy for them to make the transition.

View solution in original post

Reply
0 Kudos
7 Replies
GlenMarquis2
Enthusiast
Enthusiast
Jump to solution

http://download3.vmware.com/vmworld/2006/TAC9689-A.pdf

Page 24

I find MAC based is always better.

Reply
0 Kudos
sherold
Expert
Expert
Jump to solution

http://www.vmware-tsx.com/download.php?asset_id=41

Slide 18 and 19. EXACT same image, only the word "Mostly" added to MAC Based... So what does that ACTUALLY indicate?

If Virtual Port Based is simply performing Round Robin...which still isn't clear, it would incur less (albeit slightly) overhead than having to hash the MAC address to determine which path to use. In either case, it's literally a craps shoot to determine which NIC down a specific path will be used and how much network load it will actually generate...

I don't know that it can be determined that one is better than the other besides the fact that Virtual Port Based MAY try and keep the same number of vNICs across each path whereas there are no such guarantees with MAC based. it would be nice to have a definitive answer...

Scott

-Scott ________________________ http://www.vmguru.com http://www.thevesi.org
Reply
0 Kudos
GlenMarquis2
Enthusiast
Enthusiast
Jump to solution

Yes RoundRobin which is why I prefer MAC based.

Reply
0 Kudos
Gabrie1
Commander
Commander
Jump to solution

At TSX Event in Nice this april, there was a presentation about ESX networking. They said Mac-based is purely for compatibility reasons and they advised to use port-id based.

Or IP based in special situations.

http://www.vmware-tsx.com/download.php?asset_id=43

Pag 17 of 23

Gabrie

Message was edited by:

Gabrie

http://www.GabesVirtualWorld.com
Reply
0 Kudos
rDale
Enthusiast
Enthusiast
Jump to solution

i think that you will find the major difference between the mac and port id is the overhead. The virtual port ID is supposed to be less overhead and from what i can see; established and fixed when the vm starts up its assigns a port id to the vm and the port id is assigned to the nic that its going to go out of. I guess could be wrong but the idea was to make the port id act like a switch port and assign it to the vm whereas the mac as to build and maintain a table that controls the list of mac addresses and what port there going out of. as to round robin i see almost the same traffic on all outbound physical ports so something is keeping them balanced with port id.

RParker
Immortal
Immortal
Jump to solution

With source-MAC address forwarding, when packets are forwarded to an EtherChannel, the packets are distributed across the ports in the channel based on the source-MAC address of the incoming packet. Therefore, to provide load balancing, packets from different hosts use different ports in the channel, but packets from the same host use the same port in the channel. With destination-MAC address forwarding, when packets are forwarded to an EtherChannel, the packets are distributed across the ports in the channel based on the destination host MAC address of the incoming packet. Therefore, packets to the same destination are forwarded over the same port, and packets to a different destination are sent on a different port in the channel

______________________________________________

Technically MAC based load balancing is usual done at the hardware level. Since in ESX BOTH are controlled by the OS, there isn't much difference in overhead.

It's just setup to make it comfortable for those that KNOW the differnce. Since Virtual Ports are controlled by VI, I would think that Virtual Port would be LESS overhead than that of a MAC, since the system would have to take into account the MAC, and thus route based on incoming/outgoing traffice and analyze the origin and destination. Virtual Ports are natural, but MAC base are additional layer.

If you already had a Cisco switch with MAC based, you could offload the switch to the ESX server, and simply use the same settings. I would think that Vmware knowing all of this info, incorporated MAC based for compatibility, and if there are network engineers that want to use ESX, it would be easy for them to make the transition.

Reply
0 Kudos
bertdb
Virtuoso
Virtuoso
Jump to solution

in typical situations, there's a fixed mapping between MAC and port ID. But special VMs might send using multiple MAC addresses (cluster nodes, for example, might use a cluster MAC address in addition to their own MAC address).

Additionally, with MAC address hashing, you might get an uneven balance between ports. With 3 VMs and 3 uplinks, you're not sure that each uplink will be used.

With port ID hashing, as ports are assigned sequentially, you know that the 3 VMs have subsequent port IDs, and therefore each will be mapped to a separate uplink.