Hyper-V and Windows 10 Guest speed


  1. Posts : 1,174
    Windows 1.00 to Windows 11 Pro 64-bit Build 22000.194
       #1

    Hyper-V and Windows 10 Guest speed


    What are the best memory settings for a Windows 10 Guest on Hyper-V?

    16 Gb of physical memory
      My Computer


  2. Posts : 31,593
    10 Home x64 (22H2) (10 Pro on 2nd pc)
       #2

    fjk61011 said:
    What are the best memory settings for a Windows 10 Guest on Hyper-V
    16 Gb of physical memory
    I just take the defaults offered when setting up a new virtual machine: 1024MB initial with dynamic memory enabled. On a 16GB machine the dynamic memory will allocate more memory to the VM as required, up to a maximum of 1048576MB by default (you may want to lower that upper limit to leave some for the host). These settings work very well with any Windows guest I've tried (XP, W7, W8 & W10).

    If speed is your concern, then the hard drive is by far the more important factor. I have just migrated all my VM's from a machine with an HDD to one with an SSD. The two machines are similar specs apart from the hard drive but the difference in speed is dramatic. The VMs run as fast as if they were installed directly on the machine.
      My Computers


  3. Posts : 15,476
    Windows10
       #3

    Bree said:
    I just take the defaults offered when setting up a new virtual machine: 1024MB initial with dynamic memory enabled. On a 16GB machine the dynamic memory will allocate more memory to the VM as required, up to a maximum of 1048576MB by default (you may want to lower that upper limit to leave some for the host). These settings work very well with any Windows guest I've tried (XP, W7, W8 & W10).

    If speed is your concern, then the hard drive is by far the more important factor. I have just migrated all my VM's from a machine with an HDD to one with an SSD. The two machines are similar specs apart from the hard drive but the difference in speed is dramatic. The VMs run as fast as if they were installed directly on the machine.
    Re. SSD, totally the way to go.

    Re. dynamic memory, I have found it can be temperamental, and prefer to use fixed RAM and initially set at 4 GB but you really need at least 8 GB RAM to do this. Dynamic is better if using multiple vms and limited RAM of course.
      My Computer


  4. Posts : 31,593
    10 Home x64 (22H2) (10 Pro on 2nd pc)
       #4

    cereberus said:
    Re. dynamic memory, I have found it can be temperamental... Dynamic is better if using multiple vms and limited RAM of course.
    Well, I'l defer to your judgment, you have been VM'ing longer than me. Anyway, apart from setting it so small that the VM thrashes its swapfile, I can't see that 'tuning' the RAM could make much difference to the speed.
    ...prefer to use fixed RAM and initially set at 4 GB but you really need at least 8 GB RAM to do this.
    The OP said they have 16GB, so that should be OK.
      My Computers


  5. Posts : 17,661
    Windows 10 Pro
       #5

    As allocated RAM, an equally important factor is the number of virtual processors (vCPU) you assign to a VM.

    A good rule of thumb is to add 0.5 to 1 vCPU per VM per core on host CPU. Start testing VM performance with lower number of vCPU, for instance only one vCPU per four host cores, run the VM and check % Guest Run Time graph in Performance Monitor on host machine (not on VM). Shut down VM, increase the number of vCPU, run VM and check the graph again.

    Screenshot shows how to add % Guest Run Time graph in Performance Monitor:

    Hyper-V and Windows 10 Guest speed-image.png

    An example. A W10 PRO x64 version 1809 virtual machine using 4 GB static vRAM and two vCPU, running Windows Update. Hyper-V Manager shows its CPU usage fluctuates between 12% and 20%, and % Guest Run Time graph looks like this:

    Hyper-V and Windows 10 Guest speed-image.png

    It's OK, you should only be worried about performance if the graph for a VM shows constant high values (over 75). Peeks can be up to 90, but if either the peek value often goes to over 90, or graph remains constantly close to 75, you need more vCPU.

    Same VM, with 8 vCPU. Running WIndows Update on it looks much better, Hyper-V Manager shows CPU usage fluctuates between 1% and 3%, and the % Guest Run Time graph looks much better:

    Hyper-V and Windows 10 Guest speed-image.png

    Virtual machine also feels "snappier" with 8 vCPU.

    Kari
    Last edited by Kari; 21 Feb 2019 at 10:22. Reason: Typos.
      My Computer


  6. Posts : 1,174
    Windows 1.00 to Windows 11 Pro 64-bit Build 22000.194
    Thread Starter
       #6

    Kari said:
    As allocated RAM, an equally important factor is the number of virtual processors (vCPU) you assign to a VM.

    A good rule of thumb is to add 0.5 to 1 vCPU per VM per core on host CPU. Start testing VM performance with lower number of vCPU, for instance only one vCPU per four host cores, run the VM and check % Guest Run Time graph in Performance Monitor on host machine (not on VM). Shut down VM, increase the number of vCPU, run VM and check the graph again.

    Screenshot shows how to add % Guest Run Time graph in Performance Monitor:

    Hyper-V and Windows 10 Guest speed-image.png

    An example. A W10 PRO x64 version 1809 virtual machine using 4 GB static vRAM and two vCPU, running Windows Update. Hyper-V Manager shows its CPU usage fluctuates between 12% and 20%, and % Guest Run Time graph looks like this:

    Hyper-V and Windows 10 Guest speed-image.png

    It's OK, you should only be worried about performance if the graph for a VM shows constant high values (over 75). Peeks can be up to 90, but if either the peek value often goes to over 90, or graph remains constantly close to 75, you need more vCPU.

    Same VM, with 8 vCPU. Running WIndows Update on it looks much better, Hyper-V Manager shows CPU usage fluctuates between 1% and 3%, and the % Guest Run Time graph looks much better:

    Hyper-V and Windows 10 Guest speed-image.png

    Virtual machine also feels "snappier" with 8 vCPU.

    Kari
    Set to 4 vCPUs. Running well.
      My Computer


  7. Posts : 7
    Win10
       #7

    If using dynamic memory, I find bumping the memory buffer from 20% to 30% makes a noticeable difference in performance. If the virtual disk is on an HDD, taking it to 50% is a good idea. This lets the guest OS cache more stuff in memory.
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 22:55.
Find Us




Windows 10 Forums