What is the proper IP cofiguration for my 2 NICs and 2 VMs?

5,991

Solution 1

This might not fix your problem but...any Hyper-V box should have one NIC dedicated to administering the host (ONBOARD NIC for HOST) and one or more NICs dedicated to the VMs (Additional NIC for Hyper-V). I would do this:

  1. Delete your existing Hyper-V network in Hyper-V manager.

  2. On the host, you should now have only 2 NICs visible, ONBOARD NIC and Additional NIC. Leave ONBOARD NIC configured as above.

  3. Disable all services on Additional NIC (including IPv4 and IPv6). You don't need this NIC to be configured with an IP address - Hyper-V will just use this bit of hardware to access the network so as long as it is properly cabled to a configured switch port, they will be able to use it.

  4. Recreate your EXTERNAL network in Hyper-V Manager and make sure that you pick Additional NIC. After you do this, go back into the host's Network Control Panel and you should now see 3 NICs! When you created the Hyper-V EXTERNAL network, it then created an additional virtual NIC and added it to the list. Like the Additional NIC, it should have all services (including IPv4 and IPv6) disabled.

  5. Now turn off both VMs, reassign their NICs to the Hyper-V network, start them, and it should work.

Note: all of this applies assuming that everything is on the same subnet and there is no trunking going on for the switch port that Additional NIC is connected to. If there is trunking, you'll be assigning the VMs to a VLAN but if there is no trunking, DO NOT select the "Use VLAN" checkbox on the VM config page.

Good luck.

Solution 2

Turn off IPv4 Large Send Offloading under advanced setting for the adapter that hosts the HyperV network. Apparently the HyperV virtual switch does not handle this well. It fixed the packet drop issues for me. Hope this helps some people because it took me a while to figure it out.

Share:
5,991

Related videos on Youtube

Jason
Author by

Jason

Updated on September 17, 2022

Comments

  • Jason
    Jason over 1 year

    I have a Win2008 R2 server running Hyper-V with two VMs (Win2003 and Win2008R2).

    I have two NICs on my server, one for the host, and one for the Virtual Machine Manager.

    I have it configured as follows, but the VMS do not have access to the Internet. What am I doing wrong?

    ONBOARD NIC for HOST
    IP:      a.b.c.19  
    Mask:    255.255.255.192  
    Gateway: a.b.c.1  
    DNS1:    a.b.c.130  
    DNS1:    a.b.c.131
    
    Additional NIC for Hyper-V
    IP:      a.b.c.30
    Mask:    255.255.255.192  
    Gateway: a.b.c.1  
    DNS1:    a.b.c.130  
    DNS1:    a.b.c.131
    
    VM1
    IP:      a.b.c.9
    Mask:    255.255.255.192  
    Gateway: a.b.c.1  
    DNS1:    a.b.c.130  
    DNS1:    a.b.c.131
    
    VM2
    IP:      a.b.c.20
    Mask:    255.255.255.192  
    Gateway: a.b.c.1  
    DNS1:    a.b.c.130  
    DNS1:    a.b.c.131
    

    Should my Gateways of the VMs be configured special to point to the NIC for Hyper-V?

    • JSchlather
      JSchlather over 14 years
      Is a.b.c the same subnet for all those IP addresses?
  • Jason
    Jason over 14 years
    Thanks for the response, but yes, I have done all of that... many times over :(
  • Jason
    Jason over 14 years
    Okay, I followed this advice but it only partially worked. From the VMs, my pings were experiencing 50-75% packet loss. I could not RDP into either one successfully.
  • Helvick
    Helvick over 14 years
    Sounds like you have a problem on the physical network, if any traffic is getting through then the basic assignment of the NIC roles is probably right. Check that the uplink NIC for your VM's is set correctly and do the same on your switch for the port it's connected to.
  • Jason
    Jason over 14 years
    Without the VMs, the machine works fine... it isn't until I configure the VMs that I have this network loss. I'm trying to work with my data center, but I can't simply say it is the networks fault - in fact, I'm sure it is something else I am doing wrong... I just don't know what it is yet.
  • learnningprogramming
    learnningprogramming over 14 years
    There's nothing about the Hyper-V config that I've ever seen that could result in packet loss. Hyper-V's networking config is simple. It works or it doesn't. You have Hyper-V set correctly now. You say though that you had no packet loss before VMs. But if you followed my steps above, before VMs you had one NIC with an IP (the ONBOARD NIC). Did you see packet loss on that NIC? I suspect not. After creating the 2 VMs and adding them to the virtual network, does the ONBOARD NIC show packet loss or just the VMs? My suspicion is you have a non-Hyper issue and it is something with the Additonal NIC.
  • Stephen Jennings
    Stephen Jennings over 14 years
    This describes what I set up two weeks ago using the guidance on this question: serverfault.com/questions/38518/… . The setup is no different with Windows Server vs. SBS. Works like a champ.
  • kenwarner
    kenwarner over 13 years
    how do you perform step 3 with Hyper-V Server? I don't have a GUI to get to the adapter settings