NIC Teaming, also known as link aggregation or Load Balancing/Failover (LBFO), is a technology that allows to combine multiple network adapters into a single interface. Before Windows server 2012, this feature was accessible to us only because of different hardware vendors, who made that possible for specific network cards through drivers and software. But now this feature is included in operation system itself, providing increased bandwidth and fault tolerance. To master NIC Teaming, you must know not only the steps to join several interfaces in one. NIC teaming is a feature, that has many interesting details like modes of work in a physical server, NIC teaming in virtual environment and network settings like using VLANs. And this is why we are here for: the details. First we start with steps needed to create a NIC Team, both GUI or PowerShell, then delve into the details described earlier.

Configure NIC Teaming: Create a NIC team using Server Manager and PowerShell

Server Manager:

1.     In Server Manager, open the properties section. Then click NIC Teaming. You`ll see a window similar to:

Configure NIC Teaming1

 

 

 

 

 

2.     Click Tasks and select New Team

3.     Click Additional Properties

4.     Enter a name for the team

5.     Mark adapters you wan to join in the team

Configure NIC Teaming2

 

 

 

 

 

 

 

 

6.     Choose a teaming mode from:

  •      Static Teaming
  •      Static Teaming
  •      LACP

7.     Choose a load balancing mode from:

  •      Address Hash
  •      Hyper-V Port
  •      Dynamic

8.     If you chose is Switch Independent mode, you can choose the adapters to function as a standby adapter, or leave all adapters in active mode.

9.     Finish the NIC Team creation by clicking OK.

Now we will discuss all options of teaming and load balancing mode in more details.

Configure NIC Teaming: Modes of operation

In the NIC Teaming window, you must choose modes for Teaming and load balancing. To learn how to configure NIC teaming, you must know the meaning of every node, where are they suitable and why. Simple to remember, that there are two main modes of Teaming mode – Switch Independent and Switch Dependent (these are both Static and LACP modes) modes.

Switch Independent mode:

This mode does not require the switch to participate in teaming. The network adapters may be connected to different switches – but that is not a demand. If you choose this mode of teaming, you can mark adapters from the team to function as a standby adapters (active/passive mode) – those adapters will not be used for traffic. When one member of active team fail – one member of standby team will take its place. In the active/active mode, you gain increased output, however it will decrease in the case of failure.

 Switch Dependent mode:

As it comes from the name, this configuration requires the switch to participate in teaming, and all team members need to be connected to one switch. There are two modes of operation as well: Static teaming mode and LACP. Static teaming requires both the switch and the host to identify links that form a team – and there are no protocols for assistance or error handling in this configuration. LACP – Link Aggregation Control Protocol is used for dynamic identification of links forming the team. Team is created automatically, and typically you need make additional configuration of the switch port to enable the protocol

Configure NIC Teaming: Load balancing modes

In addition to configuring teaming mode, you must choose load balancing mode. There are three options to choose from: Hyper-V switch port, Address hashing and Dynamic.

Hyper-V switch port:

Since VMs have independent MAC addresses, the VM’s MAC address or the port it’s connected to on the Hyper-V switch can be the basis for dividing traffic. There is an advantage in using this scheme in virtualization. Because the adjacent switch always sees a particular MAC address on one and only one connected port, the switch will distribute the ingress load (the traffic from the switch to the host) on multiple links based on the destination MAC (VM MAC) address. This is particularly useful when Virtual Machine Queues (VMQs) are used as a queue can be placed on the specific NIC where the traffic is expected to arrive. However, if the host has only a few VMs, this mode may not be granular enough to get a well-balanced distribution.

Address Hashing:

This algorithm creates a hash based on address components of the packet and then assigns packets that have that hash value to one of the available adapters. Usually this mechanism alone is sufficient to create a reasonable balance across the available adapters. The components that can be specified, using PowerShell, as inputs to the hashing function include the following:

  • Source and destination TCP ports and source and destination IP addresses (this is used by the user interface when “Address Hash” is selected)
  • Source and destination IP addresses only
  • Source and destination MAC addresses only

Dynamic:

This algorithm takes the best aspects of each of the other two modes and combines them into a single mode. Outbound loads are distributed based on a hash of the TCP Ports and IP addresses. Dynamic mode also rebalances loads in real time so that a given outbound flow may move back and forth between team members. Inbound loads are distributed as though the Hyper-V port mode was in use.

So, how we can combine these options to get the best of teaming? Here are some useful combinations.

Configure NIC Teaming: Mode Combinations

Switch Independent +Address Hash:

This mode is best used for:

  • Active/Standby mode teams with just 2 team members; and
  • Teaming in a VM

Switch Independent + Hyper-V Switch Port:

Allows maximum use of Virtual Machine Queues (VMQs) for better performance over all

Switch Independent configuration + Dynamic:

This mode is best used for teaming in both native and Hyper-V environments except when:

  • Teaming is being performed in a VM,
  • Switch dependent teaming (e.g., LACP) is required by policy, or
  • Operation of a two-member Active/Standby team is required by policy.

Switch Dependent configuration + Address Hash:

Not a first-choice recommendation for any workload

Switch Dependent configuration + Hyper-V Switch Port:

Not a first-choice recommendation for any workload

Switch Dependent + Dynamic:

This mode is best used for teaming in all cases where Switch Dependent configurations are required by policy.

Configure NIC Teaming: Issues

NIC Teaming is a very powerful feature, and it must be used propertly. Here we gathered some issues in addition to understanding modes that can help you not to make a mistake.

Configure NIC Teaming: Using VLANs

  • Anytime you have NIC Teaming enabled, the physical switch ports the host is connected to should be set to trunk (promiscuous) mode. The physical switch should pass all traffic to the host for filtering without modification.[1]
  • Anytime you have NIC Teaming enabled, you must not set VLAN filters on the NICs using the NICs advanced properties settings. Let the teaming software or the Hyper-V switch (if present) do the filtering.
  • The preferred method of supporting multiple VLANs in a VM is to provide the VM multiple ports on the Hyper-V switch and associate each port with a VLAN. Never team these ports in the VM as it will certainly cause communication problems.
  • If the VM has multiple SR-IOV VFs make sure they are on the same VLAN before teaming them in the VM. It’s easily possible to configure the different VFs to be on different VLANs and, like in the previous case, it will certainly cause communication problems.

Configure NIC Teaming: Networking:

  • In Switch Independent mode with Address Hash distribution
    • All ARP and NS packets are sent on the primary team member
    • All traffic sent on NICs other than the primary team member are sent with the source MAC address modified to match the NIC on which they are sent
    • All traffic sent on the primary team member is sent with the original source MAC address (which may be the team’s source MAC address)
  • In Switch Independent mode with HyperVPort distribution
    • Every vmSwitch port is affinitized to a team member
    • Every packet is sent on the team member to which the port is affinitized
    • No source MAC replacement is done
  • In Switch Independent mode with Dynamic distribution
    • Every vmSwitch port is affinitized to a team member5
    • All ARP/NS packets are sent on the team member to which the port is affinitized
    • Packets sent on the team member that is the affinitized team member have no source MAC address replacement done
    • Packets sent on a team member other than the affinitized team member will have source MAC address replacement done
  • In Switch Dependent mode (all distributions)
    • No source MAC replacement is done

Configure NIC Teaming: PowerShell

Teams can also be created through Windows PowerShell. The Windows PowerShell to do exactly what these figures have shown is

Teams can be created with custom advanced properties:

If the team is being created in a VM, you must allow guest teaming:

For a full understanding of the Windows PowerShell commands for configuring NIC Teaming:

Now we know everything we need to master NIC Teaming. We talked about the basics of Configuring NIC Teaming through Server Manager or PowerShell, described every mode of operation and provided useful tips for creating different combinations of them. Finally, we got some details about VLANs and networking of this feature

Reference:

NIC Teaming cmdlets PowerShell

Windows Server 2012 R2 NIC Teaming (LBFO) Deployment and Management