Tuesday, December 16, 2014

Hyper-V Network Adapter Name in Windows Server 2016 (Technical Preview)

Starting from Windows Server 2016 (Technical Preview), Microsoft added Hyper-V Network Adapter Name property on Windows 10 and Windows Server 2016 (Technical Preview).


This property works with "Device naming" option of virtual NICs of virtual machines which are installed generation 2 version.


In Windows Server 2012 and Windows Server 2012 R2, we can create virtual NICs with the name which you assigned to virtual machines by performing PowerShell cmdlet, Add-VMNetworkAdapter -Name. However, virtual machines don't know the name which you assigned. Microsoft added this option, Device naming, in Windows Server Technical Preview or Windows 10 with Hyper-V for virtual machines which are installed generation 2 version.

Enabled "Device naming" option on vNICs of a virtual machine, the vNIC name will be passed to "Hyper-V Network Adapter Name" value into a virtual machine. I'm going to do a demonstration for this.

Lab environment
  • 1 Hyper-V host which is installed Windows Server Technical Preview named HV02
  • 1 generation 2 virtual machine which is installed Windows Server Technical Preview named WSTP without vNIC

Lab
Launch "PowerShell" console, perform "Add-VMNetworkAdapter -VMName WSTP -SwitchName <Virtual Switch Name> -Name <vNIC name>".


A new vNIC has been added into WSTP. Then, we need to enable Device naming option by performing "Set-VMNetworkAdapter -VMName WSTP -Name <vNIC name> -DeviceNaming On".


To check the "Hyper-V Network Adapter Name" value in a virtual machine, we can use Device Manager or PowerShell".



I hot-added a vNIC into the running virtual machine so there is no value at this moment. The virtual machine is needed to shut down and then power on to update the value. 

Remark: We can also restart the virtual machine for updating the Hyper-V Network Adapter Name value. However, I found that some types of value cannot pass to the value box by restarting virtual machine in Windows Server Technical Preview and Windows 10 Technical Preview. The value will be showed Network Adapter in Hyper-V Network Adapter Name value.




These types of value affect the result.

1. The virtual NIC name is more than 6 characters.



2. Or, the virtual NIC name included space in the whole name.



3. Or, the virtual NIC name included characters.



I think the next release will fix this minor bug.

After shut down and power on the virtual machine, the Hyper-V Network Adapter Name value has been updated into a virtual machine.



In my opinion, this is a useful feature for us to identify which NIC is a virtual machine mapped to which virtual NIC name. However, the feature only supports virtual machines which are installed Windows Server Technical Preview and Windows 10 Technical Preview. I hope the feature in the RTM version of Windows Server will support the previous operating systems like Windows Server 2012 and Windows Server 2012 R2.

More references:
Sneak Peek into the Next Release of Windows Server Hyper-V

Hot add/remove of network adapters and enabling device naming in Windows Server Hyper-V

This posting is provided “AS IS” with no warranties, and confers no rights!

No comments:

Post a Comment