Consider the following scenario: 1 Hyper-V server with two individual 1Gb/s NIC cards, each card/interface being connected to the same LAN. 2 External network virtual switches, each dedicated to a single NIC respectively. 2 Virtual machines with a single virtual network adapter. Each of the VMs' network adapters is connected to a single virtual switch respectively.

The purpose of this is to dedicate a VM's virtual network interface to its own physical network interface, such that traffic sent to one VM will not congest or subtract from available bandwidth to the other server.

My question would be, while retaining the ability to have physical network connectivity, and the ability to have a dedicated 1Gb/s pipe, is there a way to now have the two VMs be able to communicate directly with each other without using the physical network adapters, such that all network traffic between these two servers will be isolated to within the scope of the Hyper-v host? Furthermore, the theoretical bandwidth between the direct logical network connection would exceed the physical limitations of the 1Gb/s NIC card.

I was thinking this could be possible with a router either on the host or within another VM, but I was wondering if anyone had an idea of what could be a possible best practice in this situation?

  • There's no need for a router. VM's can communicate directly via a Private Virtual Switch without transiting the host physical NIC. – joeqwerty Apr 5 '17 at 18:10
  • Wouldn't that require another set of network adapters with their own separate ip addresses, potentially on another subnet, implying that the connection would have to be configured to be resolved through hard-coded ip address, rather than a common DNS resolution for all servers? If the server had both an external and private virtual switch, and the client had resolved the IP via DNS server, would it not still transit the physical adapters in order to reach the host? – KLM Apr 5 '17 at 19:10

If you would like to keep your current configuration with the VMs on separate vSwitches, you might want to look into creating a layer 2 tunnel between them. This works on top of an underlay layer 3 network, so your two VMs could even be in separate Hyper-V hosts in separate parts of your datacenter. Have a look at the virtualization gateway for more information: https://technet.microsoft.com/en-us/library/jj618319(v=ws.11).aspx

However, if your only worry is an optimized used of resources I would recommend you to simplify your setup. Go back to one vSwitch and get your VMs to share a layer 2 network. Once you're back to a manageable setup, make sure you understand and take advantage of RSS and VMQ. There's an excellent collection of deep dive blog posts about these technologies by one of the Windows Networking PMs: https://blogs.technet.microsoft.com/networking/2013/09/10/vmq-deep-dive-1-of-3/ You might also want to enable teaming on your physical NICs so your VMs can tap into a 2Gbps link.

Finally, if what you want is a hard cap of 1Gbps on each VM, you can set this up per VM in Hyper-V. In this case I would still recommend teaming the interfaces for HA purposes and keeping both VMs in the same vSwitch

Hope this helps!

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.