Lazy Diary @ Hatena Blog

PowerShell / Java / miscellaneous things about software development, Tips & Gochas. CC BY-SA 4.0/Apache License 2.0

Laggy network connection between host and guest with Hyper-V on Windows 10

Problem

  • When using Hyper-v on Windows 10, network connection between host and guest stops intermittingly.
  • You can ping from host to guest. Ping causes "Request timed out" intermittingly. Ping losses around 10% of packets.
  • Symptom doesn't change if you turn off IPSec Task Offload and Virtual Machine Queues (VMQ) on the network adapter on the guest VM.

Cause

It seems the "Default Switch" in Virtual Switch Manager causes network lag.

Solution

  1. Make a new virtual switch (i.e. "NewSwitch") in Virtual Switch Manager.
  2. Set connection type of the virtual switch to "Internal network", or "External newtork" and check "Allow management operationg system to share this network adapter". When you choose "Internal network", you have to set IP address statically on the NIC on guest VM, and on "vEthernet (NewSwitch)" host Windows. The guest cannot connect to the Internet. When you choose "External newtork", maybe you don't have to set IP address (you can use same DHCP server that the host use), but the network on the host OS causes performance degredation.