How to properly config a Hyper-V VM's settings on dual process DL380 G7

Darryl Hoar 181 Reputation points
2023-03-08T15:44:03.8233333+00:00

I have an HP Proliant DL380 G7 server. It has (2) XEON processors. It has 144GB of Ram.

The server is running Windows Server 2016 Standard. I have "installed" Hyper-V on the server.

I created a new Virtual Machine and installed Windows Server 2016 on it. Let's call the Virtual Machine MyMachine.

What setting should I use on the MyMachine vm? Since I have (2) xeon processors what should I set processors to? Anything I should be aware of when allocating Ram? Any other performance settings I should know?

I have looked at some guides but its unclear.

Thanks.

Windows for business | Windows Client for IT Pros | Storage high availability | Virtualization and Hyper-V
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Michael Taylor 60,161 Reputation points
    2023-03-08T16:18:54.8066667+00:00

    That really depends on your needs. How many VMs do you intend to host on this server? Does the server do anything besides run VMs? How much processor/memory do the VMs need to do there work?

    There is no correct answer here. You need to balance what the physical server needs to handle with what each VM requires. Let's take an example. You didn't provide the specifics of your processor but let's assume you have 2 Xeon Bronze 3206R processors. These processors have 8 cores each giving you 16 logical processors.

    Now suppose you want to run a database server in one VM and an app server in another. The app server shouldn't be too taxing on the CPU nor should it require a lot of memory but you would like to support 100s of users a second. At a minimum you'll probably want to allocate 2 logical processors but let's plan ahead and allocate 4 processors. For memory, if you're just handling requests and not loading a lot of data then you don't need much memory for the app. Assuming it is a 64-bit app then the memory is probably under 1 GB. But the server OS you're running on that VM requires more memory than that. Let's suppose you plan to run multiple apps eventually and you don't want to have to scale up later. Maybe you start with 8 GB of memory (or even 16 GB).

    If the physical server isn't doing anything else then that leaves the remaining 12 processors and 128 GB of memory for your database VM. DBs tend to want to use whatever you give them so allocate what you feel comfortable with.

    But if you're using all the memory and processors for the VMs that doesn't leave the physical server with anything. If it is just a VM server then that is fine but if you also intend for it to do some other work like be a file server then you might want to back off a little on your DB VM and give a processor or 2 and a couple of GBs of memory to the host server.

    There is ROI challenge here that only you can address. The general rule of thumb is that you should be using 75-80% of your resources on average otherwise you're wasting them. So profile your VMs (and host server). If you find that you're almost never using enough of the processor/memory you allocated then back off on the configuration. This leaves you more room to expand later and, if another VM requires more resources, then you have some room to adjust. This is something you have to constantly monitor and adjust as your workloads change.

    In terms of additional options you probably want to configure dynamic memory in Hyper-V such that it only allocates memory when it needs it. Otherwise the VM will allocate all the memory up front. Having said that, some VMs do better with allocating the memory up front. The DB VM should likely allocate all its memory up front so it is running as fast as possible. But your app server isn't really going to be slowed down if the VM doesn't get the memory it needs until it asks for it. Again, profile the behavior with realistic workloads to confirm.

    0 comments No comments

  2. JimmySalian-2011 42,491 Reputation points
    2023-03-08T16:26:31.87+00:00

    @Darryl Hoar you can select the config as per the server role and requirements, if it is a test server you can always start with low spec and test the performance of the VM. Gradually you can increase the spec of the server depedning on the performance and app requirements - Check the process and configuration of Hyper V Virtual machines over here - https://learn.microsoft.com/en-us/windows-server/virtualization/hyper-v/get-started/create-a-virtual-machine-in-hyper-v?tabs=hyper-v-manager

    https://learn.microsoft.com/en-us/windows-server/virtualization/hyper-v/plan/should-i-create-a-generation-1-or-2-virtual-machine-in-hyper-v

    Hope this helps.

    JS

    ==

    Please accept as answer and do a Thumbs-up to upvote this response if you are satisfied with the community help. Your upvote will be beneficial for the community users facing similar issues.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.