Cloud and Datacenter Management Blog

Microsoft Hybrid Cloud blogsite about Management

Technical Overview Windows Server 2012 NIC Teaming #WS2012 #Hyperv

1 Comment


Technical Overview
Existing architectures for NIC teaming
Today virtually all NIC teaming solutions on the market have an architecture similar to that shown in Figure 1.

Figure 1 – Standard NIC teaming solution architecture and Microsoft vocabulary
One or more physical NICs are connected into the NIC teaming solution common core, which then presents one or more virtual adapters (team NICs [tNICs] or team interfaces) to the operating system. There are a variety of algorithms that distribute outbound traffic between the NICs.
The only reason to create multiple team interfaces is to logically divide inbound traffic by virtual LAN (VLAN). This allows a host to be connected to different VLANs at the same time. When a team is connected to a Hyper-V switch all VLAN segregation should be done in the Hyper-V switch instead of in the NIC Teaming software.

Configurations for NIC Teaming
There are two basic configurations for NIC Teaming.
*  Switch-independent teaming. This configuration does not require the switch to participate in the teaming. Since in switch-independent mode the switch does not know that the network adapter is part of a team in the host, the adapters may be connected to different switches. Switch independent modes of operation do not require that the team members connect to different switches; they merely make it possible.
* Active/Standby Teaming : Some administrators prefer not to take advantage of the bandwidth aggregation capabilities of NIC Teaming. These administrators choose to use one NIC for traffic (active) and one NIC to be held in reserve (standby) to come into action if the active NIC fails. To use this mode set the team in Switch-independent teaming. Active/Standby is not required to get fault tolerance; fault tolerance is always present anytime there are at least two network adapters in a team.
*  Switch-dependent teaming. This configuration that requires the switch to participate in the teaming. Switch dependent teaming requires all the members of the team to be connected to the same physical switch.
There are two modes of operation for switch-dependent teaming:
* Generic or static teaming (IEEE 802.3ad draft v1). This mode requires configuration on both the switch and the host to identify which links form the team. Since this is a statically configured solution there is no additional protocol to assist the switch and the host to identify incorrectly plugged cables or other errors that could cause the team to fail to perform. This mode is typically supported by server-class switches.
* Dynamic teaming (IEEE 802.1ax, LACP). This mode is also commonly referred to as IEEE 802.3ad as it was developed in the IEEE 802.3ad committee before being published as IEEE 802.1ax. IEEE 802.1ax works by using the Link Aggregation Control Protocol (LACP) to dynamically identify links that are connected between the host and a given switch. This enables the automatic creation of a team and, in theory but rarely in practice, the expansion and reduction of a team simply by the transmission or receipt of LACP packets from the peer entity. Typical server-class switches support IEEE 802.1ax but most require the network operator to administratively enable LACP on the port.
Both of these modes allow both inbound and outbound traffic to approach the practical limits of the aggregated bandwidth because the pool of team members is seen as a single pipe.

Algorithms for traffic distribution
Outbound traffic can be distributed among the available links in many ways. One rule that guides any distribution algorithm is to try to keep all packets associated with a single flow (TCP-stream) on a single network adapter. This rule minimizes performance degradation caused by reassembling out-of-order TCP segments.
NIC teaming in Windows Server 2012 supports the following traffic distribution algorithms:
*  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. This mode will also always limit a single VM (i.e., the traffic from a single switch port) to the bandwidth available on a single interface. Windows Server 2012 uses the Hyper-V Switch Port as the identifier rather than the source MAC address as, in some instances, a VM may be using more than one MAC address on a switch port.
* 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 as inputs to the hashing function include the following:
* Source and destination MAC addresses
*  Source and destination IP addresses
* Source and destination TCP ports and source and destination IP addresses
The TCP ports hash creates the most granular distribution of traffic streams resulting in smaller streams that can be independently moved between members. However, it cannot be used for traffic that is not TCP or UDP-based or where the TCP and UDP ports are hidden from the stack, such as IPsec-protected traffic. In these cases, the hash automatically falls back to the IP address hash or, if the traffic is not IP traffic, to the MAC address hash.

Interactions between Configurations and Load distribution algorithms
Switch Independent configuration / Address Hash distribution
This configuration will send packets using all active team members distributing the load through the use of the selected level of address hashing (defaults to using TCP ports and IP addresses to seed the hash function).
Because a given IP address can only be associated with a single MAC address for routing purposes, this mode receives inbound traffic on only one team member (the primary member). This means that the inbound traffic cannot exceed the bandwidth of one team member no matter how much is getting sent.
This mode is best used for:
a) Native mode teaming where switch diversity is a concern;
b) Active/Standby mode teams; and
c) Teaming in a VM.

It is also good for:
d) Servers running workloads that are heavy outbound, light inbound workloads (e.g., IIS).

Switch Independent configuration / Hyper-V Port distribution
This configuration will send packets using all active team members distributing the load based on the Hyper-V switch port number. Each Hyper-V port will be bandwidth limited to not more than one team member’s bandwidth because the port is affinitized to exactly one team member at any point in time.
Because each VM (Hyper-V port) is associated with a single team member, this mode receives inbound traffic for the VM on the same team member the VM’s outbound traffic uses. This also allows maximum use of Virtual Machine Queues (VMQs) for better performance over all.
This mode is best used for teaming under the Hyper-V switch when
a) The number of VMs well-exceeds the number of team members; and
b) A restriction of a VM to not greater than one NIC’s bandwidth is acceptable

Switch Dependent configuration / Address Hash distribution
This configuration will send packets using all active team members distributing the load through the use of the selected level of address hashing (defaults to 4-tuple hash).
Like in all switch dependent configurations, the switch determines how to distribute the inbound traffic among the team members. The switch is expected to do a reasonable job of distributing the traffic across the team members but it has complete independence to determine how it does so.
Best used for:
a) Native teaming for maximum performance and switch diversity is not required; or
b) Teaming under the Hyper-V switch when an individual VM needs to be able to transmit at rates in excess of what one team member can deliver.

Switch Dependent configuration / Hyper-V Port distribution
This configuration will send packets using all active team members distributing the load based on the Hyper-V switch port number. Each Hyper-V port will be bandwidth limited to not more than one team member’s bandwidth because the port is affinitized to exactly one team member at any point in time.
Like in all switch dependent configurations, the switch determines how to distribute the inbound traffic among the team members. The switch is expected to do a reasonable job of distributing the traffic across the team members but it has complete independence to determine how it does so.
Best used when:
a) Hyper-V teaming when VMs on the switch well-exceed the number of team members and
b) When policy calls for switch dependent (e.g., LACP) teams and
c) When the restriction of a VM to not greater than one NIC’s bandwidth is acceptable.

 NIC teaming inside of Virtual Machines (VMs)
NIC Teaming in a VM only applies to VM-NICs connected to external switches. VM-NICs connected to internal or private switches will show as disconnected when they are in a team.

NIC teaming in Windows Server 2012 may also be deployed in a VM. This allows a VM to have virtual NICs (synthetic NICs) connected to more than one Hyper-V switch and still maintain connectivity even if the physical NIC under one switch gets disconnected. This is particularly important when working with Single Root I/O Virtualization (SR-IOV) because SR-IOV traffic doesn’t go through the Hyper-V switch and thus cannot be protected by a team in or under the Hyper-V host. With the VM-teaming option an administrator can set up two Hyper-V switches, each connected to its own SR-IOV-capable NIC.
*  Each VM can have a virtual function (VF) from one or both SR-IOV NICs and, in the event of a NIC disconnect, fail-over from the primary VF to the back-up adapter (VF).
*  Alternately, the VM may have a VF from one NIC and a non-VF VM-NIC connected to another switch. If the NIC associated with the VF gets disconnected, the traffic can fail-over to the other switch without loss of connectivity.

Note: Because fail-over between NICs in a VM might result in traffic being sent with the MAC address of the other VM-NIC, each Hyper-V switch port associated with a VM that is using NIC Teaming must be set to allow teaming There are two ways to enable NIC Teaming in the VM:
1) In the Hyper-V Manager, in the settings for the VM, select the VM’s NIC and the Advanced Settings item, then enable the checkbox for NIC Teaming in the VM. See Figure 4.

2) Run the following Windows PowerShell cmdlet in the host with elevated (Administrator) privileges.
Set-VMNetworkAdapter -VMName -AllowTeaming On
Teams created in a VM can only run in Switch Independent configuration, Address Hash distribution mode (or one of the specific address hashing modes). Only teams where each of the team members is connected to a different external Hyper-V switch are supported.
Teaming in the VM does not affect Live Migration. The same rules exist for Live Migration whether or not NIC teaming is present in the VM.
No teaming of Hyper-V ports in the Host Partition
Hyper-V virtual NICs exposed in the host partition (vNICs) must not be placed in a team. Teaming of virtual NIC’s (vNICs) inside of the host partition is not supported in any configuration or combination. Attempts to team vNICs may result in a complete loss of communication in the event that network failures occur.
Feature compatibilities
NIC teaming is compatible with all networking capabilities in Windows Server 2012 with five exceptions: SR-IOV, RDMA, Native host Quality of Service, TCP Chimney, and 802.1X Authentication.
* For SR-IOV and RDMA, data is delivered directly to the NIC without passing it through the networking stack (in the host OS in the case of virtualization). Therefore, it is not possible for the team to look at or redirect the data to another path in the team.
* When QoS policies are set on a native or host system and those policies invoke minimum bandwidth limitations, the overall throughput through a NIC team will be less than it would be without the bandwidth policies in place.
*  TCP Chimney is not supported with NIC teaming in Windows Server 2012 since TCP Chimney has the entire networking stack offloaded to the NIC.
* 802.1X Authentication should not be used with NIC Teaming and some switches will not permit configuration of both 802.1X Authentication and NIC Teaming on the same port.

Table 2 – Feature interactions with NIC teaming

NIC Teaming and Virtual Machine Queues (VMQs)
VMQ and NIC Teaming work well together; VMQ should be enabled anytime Hyper-V is enabled. Depending on the switch configuration mode and the load distribution algorithm, NIC teaming will either present VMQ capabilities to the Hyper-V switch that show the number of queues available to be the smallest number of queues supported by any adapter in the team (Min-queues mode) or the total number of queues available across all team members (Sum-of-Queues mode). Specifically,
* if the team is in Switch-Independent teaming mode and the Load Distribution is set to Hyper-V Port mode, then the number of queues reported is the sum of all the queues available from the team members (Sum-of-Queues mode);
*  otherwise the number of queues reported is the smallest number of queues supported by any member of the team (Min-Queues mode).
Here’s why.
*  When the team is in switch independent/Hyper-V Port mode the inbound traffic for a VM will always arrive on the same team member. The host can predict which member will receive the traffic for a particular VM so NIC Teaming can be more thoughtful about which VMQ Queues to allocate on a particular team member. NIC Teaming, working with the Hyper-V switch, will set the VMQ for a VM on exactly one team member and know that inbound traffic will hit that queue.
*  When the team is in any switch dependent mode (static teaming or LACP teaming), the switch that the team is connected to controls the inbound traffic distribution. The host’s NIC Teaming software can’t predict which team member will get the inbound traffic for a VM and it may be that the switch distributes the traffic for a VM across all team members. As a result the NIC Teaming software, working with the Hyper-V switch, programs a queue for the VM on every team member, not just one team member.
* When the team is in switch-independent mode and is using an address hash load distribution algorithm, the inbound traffic will always come in on one NIC (the primary team member) – all of it on just one team member. Since other team members aren’t dealing with inbound traffic they get programmed with the same queues as the primary member so that if the primary member fails any other team member can be used to pick up the inbound traffic and the queues are already in place.
There are a few settings that will help the system perform even better.
Each NIC has, in its advanced properties, values for *RssBaseProcNumber and *MaxRssProcessors.
*  Ideally each NIC should have the *RssBaseProcNumber set to an even number greater than or equal to two (2). This is because the first physical processor, Core 0 (logical processors 0 and 1), typically does most of the system processing so the network processing should be steered away from this physical processor. (Some machine architectures don’t have two logical processors per physical processor so for such machines the base processor should be greater than or equal to 1. If in doubt assume your host is using a 2 logical processor per physical processor architecture.)
*  If the team is in Sum-of-Queues mode the team members’ processors should be, to the extent possible, non-overlapping. For example, in a 4-core host (8 logical processors) with a team of 2 10Gbps NICs, you could set the first one to use base processor of 2 and to use 4 cores; the second would be set to use base processor 6 and use 2 cores.
*  If the team is in Min-Queues mode the processor sets used by the team members must be identical.

NIC Requirements and limitations
Number of NICs in a team in a native host
NIC teaming requires the presence of at least one Ethernet NIC. A team of one NIC may be used for separation of traffic using VLANs. Obviously a team with only one team member has no failure protection. Fault protection (failover) requires a minimum of two Ethernet NICs in the team. The Windows Server 2012 implementation supports up to 32 NICs in a team.
Number of NICs in a team in a Hyper-V VM
The Windows Server 2012 NIC Teaming solution supports teams with two members in VMs. Larger teams can be created but such teams are not supported.
Types of NICs in a team
Any Ethernet NIC that has passed the Windows Hardware Qualification and Logo test (WHQL tests) may be used in a Windows Server 2012 team.
NICs representing technologies other than Ethernet are not supported in teams (e.g., WWAN, WLAN, Bluetooth, Infiniband).
Number of team interfaces for a team
Windows Server 2012 supports up to 32 team interfaces.

Teaming of different speed NICs
Teaming of NICs capable of operating at different speeds but presently operating at the same speed is supported.
Teaming of NICs with different speed connections is not supported. The teaming software will allow you to build such a team; however the traffic distribution algorithms in this release do not base the distribution on the speeds of the connections. A team consisting of a 10Gbps NIC and a 100Mbps NIC will send approximately half of the traffic to each NIC.
If you are creating a team where one team member will be active and another will be available to help out if the active team member fails (active/standby mode, see Section 3.2), a lower speed NIC may be used as the standby NIC so that connectivity is maintained. It is not recommended or supported for active/active configurations.
Teams of teams
A Team of teams is a team where the team members are actually team interfaces from other teams. This is not supported in the Windows Server 2012 NIC Teaming solution. Furthermore, attempting to place the team interface from a 3rd-party teaming solution into a Microsoft team may result in an unstable system that may lose connectivity to the network. DO NOT mix elements of 3rd-party teaming solutions with elements of Microsoft’s NIC Teaming solution.
MAC address use and management
In switch independent / address hash configuration the team will use the MAC address of the primary team member (one selected from the initial set of team members) on outbound traffic. MAC addresses get used differently depending on the configuration and load distribution algorithm selected. This can, in unusual circumstances, cause a MAC address conflict.
Specifically, if the primary team member is removed from the team and then placed into operation there may be a MAC address conflict. To resolve this conflict disable and enable the team interface. The process of doing a disable and enable operation on the team interface will cause it to select a new MAC address from the remaining team members.
Industry terms for NIC Teaming
Here are some other terms that are used in the context of NIC Teaming and what they are called in Windows Server 2012:

Dangers of using a powerful tool (Troubleshooting)
When a carpenter buys a nail gun because he wants to be able to build more quickly it comes with a warning that misuse of the tool can result in serious damage to oneself. NIC Teaming and the powerful administration tools in Windows Server 2012 are very powerful tools that can be misused, misconfigured, and may cause loss of connectivity if the administrator isn’t careful. Here are some common issues:
Using VLANs
VLANs are another powerful tool. There are a few rules for using VLANs that will help to make the combination of VLANs and NIC Teaming a very positive experience.
1) 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.
2) 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.
VLANs in a Hyper-V host
1) In a Hyper-V host VLANs should be configured only in the Hyper-V switch, not in the NIC Teaming software. Configuring team interfaces with VLANs can easily lead to VMs that are unable to communicate on the network due to collisions with VLANs assigned in the Hyper-V switch.
VLANs in a Hyper-V VM
1) 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.
2) 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.
3) The only safe way to use VLANs with NIC Teaming in a guest is to team Hyper-V ports that are
a. Each connected to a different Hyper-V switch, and
b. Each configured to be associated with the same VLAN (or all associated with untagged traffic only).
c. If you must have more than one VLAN exposed into a guest OS consider renaming the ports in the guest to indicate what the VLAN is. E.g., if the first port is associated with VLAN 12 and the second port is associated with VLAN 48, rename the interface vEthernet to be vEthernetVLAN12 and the other to be vEthernetVLAN48. (Renaming interfaces is easy using the Windows PowerShell Rename-NetAdapter cmdlet or by going to the Network Connections panel in the guest and renaming the interfaces.
Interactions with other teaming solutions
Some users will want to use other NIC teaming solutions for a variety of reasons. This can be done but there are some risks that the system administrator should be aware of.
1. If the system administrator attempts to put a NIC into a 3rd party team that is presently part of a Microsoft NIC Teaming team, the system will become unstable and communications may be lost completely.
2. If the system administrator attempts to put a NIC into a Microsoft NIC Teaming team that is presently part of a 3rd party teaming solution team the system will become unstable and communications may be lost completely.
As a result it is STRONGLY RECOMMENDED that no system administrator ever run two teaming solutions at the same time on the same server. The teaming solutions are unaware of each other’s existence resulting in potentially serious problems.
In the event that an administrator violates these guidelines and gets into the situation described above the following steps may solve the problem.
1. Reboot the server. Forcibly power-off the server if necessary to get it to reboot.
2. When the server has rebooted run this Windows PowerShell cmdlet:
Get-NetLbfoTeam | Remove-NetLbfoTeam
3. Use the 3rd party teaming solution’s administration tools and remove all instances of the 3rd party teams.
4. Reboot the server again.
Microsoft continues its longstanding policy of not supporting 3rd party teaming solutions. If a user chooses to run a 3rd party teaming solution and then encounters networking problems, the customer should call their teaming solution provider for support. If the issue is reproducible without the 3rd party teaming solution in place, please report the problem to Microsoft.
Disabling and Enabling with Windows PowerShell
The most common reason for a team to not be passing traffic is that the team interface is disabled. We’ve seen a number of cases where attempts to use the power of Windows PowerShell have resulted in unintended consequences. For example, the sequence:
Disable-NetAdapter *
Enable-NetAdapter *
does not enable all the netadapters that it disabled. This is because disabling all the underlying physical member NICs will cause the team interface to be removed and no longer show up in Get-NetAdapter. Thus the Enable-NetAdapter * will not enable the team NIC since that adapter has been removed. It will however enable the member NICs, which will then cause the team interface to show up. The team interface will still be in a “disabled” state since you have not enabled it. Enabling the team interface will cause traffic to begin to flow again.

Managing NIC Teaming in Windows Server 2012
Windows Server 2012 has two inbox management tools for managing NIC Teaming. Other Microsoft management products may also provide the ability to manage Windows Server 2012 NIC teaming. Windows 8 client SKUs that allow the installation of the Remote Server Administration Tools (RSAT) are also able to manage NIC teaming on Windows Server 2012 hosts.
This section provides a detailed presentation of the NIC Teaming management UI. For each operation the equivalent Windows PowerShell cmdlets will be provided. The NIC Teaming management UI operates exclusively through the use of Windows PowerShell underneath. Everything the UI does can be done with Windows PowerShell. The NIC Teaming Windows PowerShell module is NetLbfo and all the cmdlet names start with NetLbfo.
For a full understanding of the Windows PowerShell commands for NIC Teaming,
Get-Command -Module NetLbfo
will return a list of all the NIC Teaming Windows PowerShell commands as shown in Figure 5 .

Executing the Windows PowerShell command Get-Help will provide a full syntax and all the options available.
Get-Help New-NetLbfoTeam is shown in Figure 6.

Invoking the Management UI for NIC Teaming
There are three common ways to start the NIC Teaming Management UI tool.
*  From the Server Manager Local Server window (In the NIC Teaming item click on Disabled or Enabled)

*  From the Server Manager All Servers window right-click on the server to be managed and select the Configure Network Adapter Teaming action.

* From a command prompt or Windows PowerShell prompt: execute LbfoAdmin.exe.
*  The first time the NIC Teaming UI (LbfoAdmin.exe) is run, if it is invoked with no arguments it will attempt to manage NIC teaming on the local host. If the /servers flag is present then all the servers in the list of servers that follows will be included in the servers to be managed.
*  If the system detects that a server is already in the list of managed servers it will not add it to the list.
*  It is possible for the same server to appear more than once in the list especially where the name is presented differently (e.g., once with just the machine name and once with a fully-qualified machine name).
*  After the first time the NIC Teaming UI has been run it will remember the set of servers you last managed and will attempt to continue to manage that set of servers.
*  To cause the NIC Teaming UI to forget the previous settings, restore initial settings, and run like it was the first time invocation, run
LbfoAdmin.exe /ResetConfig


The components of the NIC Teaming Management UI

The NIC Teaming management UI consists of 3 primary windows (tiles):
*  The Servers tile
* The Teams tile
* The Adapters and Interfaces tile

The Adapters and Interfaces tile is shared by two tabs:
• The Network Adapters tab
• The Team Interfaces tab

Each tile or tab has a set of columns that can be shown or hidden. The column chooser menus are made visible by right-clicking on any column header. (For illustrative purposes the screen shot in Figure 12 shows a column chooser in every tile. Only one column chooser can be active at a time.)
Contents of any tile may be sorted by any column. To sort by a particular column left click on the column title. In Figure 12 the Servers tile is sorted by Server Name; the indication is the little triangle in the Name column title in the Servers tile.

Each tile also has a Tasks dropdown menu and a right-click context menu. The Tasks menus can be opened by clicking on the Tasks box at the top right corner of the tile and then any available task in the list can be selected. The right-click context menus are activated by right-clicking in the tile. The menu options will vary based on context. (For illustrative purposes the screen shot in Figure 13 shows all the Tasks menus and a right-click menu in every tile. Only one right-click menu or Tasks menu can be active at any time.) Figure 14 shows the Tasks menus and right-click menu for the Team Interfaces tab.

Adding a server to be managed
To add a server to the list of servers to be managed, i.e., the list of servers in the Servers tile, select the Servers tile Tasks menu. Selecting the Add servers action will pop-up the Add server dialog box. The Add server dialog box for the NIC Teaming UI is the same as the Add server dialog box for Server Manager.
Removing a server from the managed servers list
To remove a server from the list of managed servers right click on the server to be deleted and then select the Remove server action.
Creating a team
There are two ways to invoke the New Team dialog box:
* Select the Tasks menu in the Teams tile and then select New Team, or
*  Right click on an available adapter in the Network Adapters tab and select the Add to new team item. Multi-select works for this: you can select multiple adapters, right-click on one, select Add to new team, and they will all be pre-marked in the New Team dialog box.
Both of these will cause the New Team dialog box to pop-up.

When the New Team dialog box pops-up there are two actions that MUST be taken before the team can be created:
*  A Team name must be provided, and
*  One or more adapters must be selected to be members of the team
Optionally, the administrator may select the Additional properties item and configure the teaming mode, load distribution mode, and the name of the first (primary) team interface.

In Additional properties the Load distribution mode drop-down provides only two options: Address Hash and Hyper-V Port. The Address Hash option in the UI is the equivalent of the TransportPorts option in Windows PowerShell. To select additional Address hashing algorithms use Windows PowerShell as described below.
This is also the place where those who want to have a Standby adapter in the team  to set the Standby adapter. Selecting the Standby adapter drop-down will give a list of the team members. The administrator can set one of them to be the Standby Adapter. A Standby adapter is not used by the team unless and until another member of the team fails. Standby adapters are only permitted in Switch Independent mode. Changing the team to any Switch Dependent mode will cause all members to be made active members.
When the team name, the team members, and optionally any additional properties (including the Primary team interface name or standby adapter) have been set to the administrator’s choices, the administrator will click on the OK button and the team will be created. Team creation may take several seconds and the NICs that are becoming team members will lose communication for a very short time.
Teams can also be created through Windows PowerShell. The Windows PowerShell to do exactly what these figures have shown is
New-NetLbfoTeam Team1 NIC1,NIC2
Teams can be created with custom advanced properties.
New-NetLbfoTeam Team1 NIC1,NIC2 -TeamingMode LACP
LoadBalancingAlgorithm HyperVPorts
If the team is being created in a VM, you MUST follow the instructions to allow guest teaming as described.

Checking the status of a team
Whenever the NIC Teaming UI is active the current status of all NICs in the team, the status of the team, and the status of the server will be shown. In Figure 17, in the Network Adapters tab of the Adapters and Interfaces tile, NIC 3 shows as faulted. The reason given is Media Disconnected (i.e., the cable is unplugged). This causes the team, Team1, to show a Warning as it is still operational but degraded. If all the NICs in the team were faulted it would show Fault instead of Warning. The server, DONST-R710, now shows Warning. If the team was not operational the server indication would be Fault. This makes it easy to scan the list of servers to see if there are any problems.

Modifying a team
Modifying a team through the UI
Within the UI, modifications to the team can be done by selecting a team in the Team tile, right-clicking on the team, and selecting the Modify Team action. Selecting Modify Team will pop-up the Team properties dialog box. This dialog box is very similar to the New Team dialog box as described.
In the Team properties dialog box the following actions can be accomplished:
*  Rename the team: Select the team name and edit it.
*  Add team members: Select additional adapters from the Member Adapters tile
*  Remove team members: De-select adapters from the Member Adapters tile. At least one adapter must be selected.

If the Additional properties drop-down item is selected then the Teaming mode and Load distribution mode may also be modified. This Additional properties drop-down also allows the administrator to select a standby adapter when active-standby mode is desired.


Modifying a team through Windows PowerShell
Renaming a team
To rename Team1 and give it the name TeamA, the Windows PowerShell is:
Rename-NetLbfoTeam Team1 TeamA
Changing the teaming mode
The Windows PowerShell options for teaming mode are:
*  SwitchIndependent
*  Static
*  LACP

To change Team1 to an 802.1ax LACP team, the Windows PowerShell is:
Set-NetLbfoTeam Team1 TeamingMode LACP
The “-TeamingMode” flag can be abbreviated “-TM”, as in
Set-NetLbfoTeam Team1 –TM LACP
Note: For security reasons teams created in VMs may only operate in SwitchIndependent mode.
Changing the load distribution algorithm
The Windows PowerShell options for load distribution algorithm are:
*  TransportPorts
* IPAddresses
*  MacAddresses
* HyperVPort

To change Team1’s Load balancing algorithm to Hyper-V Ports, the Windows PowerShell is:
Set-NetLbfoTeam Team1 LoadBalancingAlgorithm HyperVPorts
The “-LoadBalancingAlgorithm” flag can be abbreviated “-LBA”, as in
Set-NetLbfoTeam Team1 LBA HyperVPorts
To change the Teaming mode and Load balancing algorithm at the same time,
Set-NetLbfoTeam Team1 TM LACP LBA HyperVPorts
Note: Teams created in VMs may not use the HyperVPort load distribution algorithm.
Adding new members to the team
To add NIC1 to Team1 the Windows PowerShell command is:
Add-NetLbfoTeamMember NIC1 Team1
Removing members from the team
To remove NIC1 from Team1 the Windows PowerShell command is:
Remove-NetLbfoTeamMember NIC1 Team1
Setting a team member to be the Standby Adapter
A team member can be set as the Standby Adapter through Windows PowerShell:
Set-NetLbfoTeamMember NIC4 -AdministrativeMode Standby
At most one team member may be in standby mode at any point in time. If a different team member is already in standby mode that team member must be returned to active mode before this Windows PowerShell cmdlet will succeed.
Adding new interfaces to the team
To add a new interface to the team select the Team in the Teams Tile and the Team Interfaces tab in the Adapters and Interfaces tile. Select the Tasks menu in the Adapters and Interfaces tile, then select Add Interface.

Selecting the Add Interface action item pops-up the New team interface dialog box.

Since only one team interface, the primary team interface, can be in Default mode, the new team interface must have a specific VLAN value. As the specific VLAN value is entered the name of the interface will be modified to be the team name followed by the VLAN value of this team interface. The interface name can be modified to any other name (duplicates are not allowed) if the administrator chooses to do so.
Selecting OK will create the new team interface.

The Windows PowerShell to add a team interface with VLAN 42 to Team1 is
Add-NetLbfoTeamNIC Team1 42
Modifying team interfaces
There are only two modifications that can be done to a team interface:
*  change the team interface name and/or
*  change the VLAN ID.
To modify the team interface VLAN ID select and then right-click the team interface in the Team Interfaces tab. Select the Properties action item.

This pops-up the Network Adapter Properties dialog box. This dialog box has some useful information about the team interface. It also has the box where the new VLAN ID can be entered. If a new VLAN ID is entered and the team name is the one the system provided when the team interface was created the team interface name will be changed to reflect the new VLAN ID. If the team interface name has been previously changed then the team name will not be changed when the new VLAN ID is entered.

To modify a team interface’s VLAN ID in Windows PowerShell
Set-NetLbfoTeamNIC “Team1 VLAN 42” -VlanID 15
Just as in the UI, changing the VLAN ID will cause the team interface name to change if the team interface name is still the same as the one the system created when the team interface was created. I.e., if the team interface name is where xx is the VLAN ID of the team interface, then the VLAN ID portion of the team interface name will be modified to reflect the new VLAN ID.
Removing interfaces from the team
To delete a team interface, select and then right-click the team interface in the Team Interfaces tab. Select the Delete team interface action item. (See Figure 23.) A confirmation dialog box will pop-up. Once confirmed the team interface is deleted.
The Primary team interface (i.e., the one that was created when the team was created) can’t be deleted except by deleting the team.
To delete a team interface in Windows PowerShell
Remove-NetLbfoTeamNIC “Team1 VLAN 42”

  Deleting a team
To delete a team from the server select the team in the Teams tile. Right-click the team and select the Delete team action item.

A confirmation dialog box will be displayed. Once confirmed the team will be deleted.
To delete a team in Windows PowerShell
Remove-NetLbfoTeam Team1
To remove all teams from the server in Windows PowerShell (i.e., to clean up the server),
Get-NetLbfoTeam | Remove-NetLbfoTeam
Viewing statistics for a team or team member
If the UI window is sufficiently tall a statistics tile appears at the bottom of the Team tile and the Adapters and Interfaces tile. These statistics windows reflect the traffic of the selected team and selected team member. If you don’t see the statistics try making the UI window a little taller.

Viewing statistics for a team interface
If the Team Interfaces tab is selected in the Adapters and Interfaces tile the statistics at the bottom of the Adapters and Interfaces tile will be those of the selected team interface.

Setting frequency of Statistics updates
The frequency of statistics updates and other updates can be set by selection Settings in the Servers tile Tasks menu. Selecting this item brings up the General Settings dialog box.

The two drop-down lists in this dialog box allow the user to change how often the UI is . refreshed. The settings apply equally to all servers in the servers list.
This menu also allows the administrator to decide whether or not adapters that are not able to be part of a team should be shown in the UI. By default these non-teamable adapters are not shown.

Power User tips for the NIC Teaming User Interface
Here are some power-user tips for the NIC Teaming UI:
Quickly return to your most commonly-used servers. When you add a server to the NIC Teaming UI, you can quickly bring up that server again with the Windows taskbar’s Jump List. Right-click on the taskbar icon for NIC Teaming, and select the server name from the list. That’s it!
Customizing the UI. As mentioned, columns may be added or removed from any tile. What that section didn’t mention is that tile contents may be sorted by any column. So, for example, the Servers tile could be sorted by the Server Type column so that the Physical Servers showed up above (or below) the Virtual Servers (VMs). Network adapters could be sorted by Speed or State, for example, if the administrator wanted that ordering instead of the default ordering.
Reset the GUI and start from scratch. The GUI will remember the servers you’ve added, the position of the main window, which columns you’ve hidden and shown, and any search filters you’ve saved. Most of the time, this is great. But if you ever want to start over with a clean slate, you can run
LbfoAdmin.exe /ResetConfig
to wipe away your old GUI settings, and load up the defaults. Of course, this will not affect the teams on any of your servers; it only resets GUI state.
Navigate the GUI from your keyboard. Keyboard lovers will appreciate these accelerators. You may have already guessed that F5 refreshes server status. But you can also hit ALT+1 to set focus to the Servers tile, ALT+2 to move to the Teams tile, ALT+3 to activate the Adapters tile, and ALT+4 to focus the Team Interfaces tile.
Authenticate to a non-domain-joined computer. If you would like to use different credentials to manage a remote server, you can right-click on the server name and select “Use Credentials…”. This feature is built on the same WinRM management technology as Windows PowerShell, and it can be configured in the same way. By default, non-domain-joined servers are not trusted for authentication. If you would like to allow a server to be trusted, you can use the Windows PowerShell command:
Set-Item WSMan:\localhost\Client\TrustedHosts myserver -Concatenate
This will allow you to authenticate against a server named “myserver”, whether you are using the Windows PowerShell Get-Credential cmdlet, or whether you are managing the server in the NIC Teaming UI. Caution: this lowers the default security settings so you should only use this command in a trusted environment.
NIC Teaming speaks your language. If you manage servers in a multi-lingual environment, you might notice NetLbfo Windows PowerShell cmdlets or the NIC Teaming UI giving you messages in the wrong language. Some messages (most commonly, error messages) come from the target server, and are selected from the target server’s set of installed languages. You can install your favorite language pack on the target server to change the language of the server-generated messages.

Author: James van den Berg

I'm Microsoft Architect and ICT Specialist and Microsoft MVP Cloud and Datacenter Management Microsoft MVP Windows Insider Microsoft Tech Community Insider Microsoft Azure Advisor

One thought on “Technical Overview Windows Server 2012 NIC Teaming #WS2012 #Hyperv

  1. This must be the most complete description of nic teaming in a 2012 hyper-v environment, very helpful, thank you

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.