• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2601
  • Last Modified:

CPU / sockets settings for two Hyper-V guests on a dual CPU/quad core host

hi all,

I've been  reading for some hours but i am totally confused with all the conflicting info.

I have a new Dell server with two quad core CPUs running Server 2012 R2 standard.  I have created two Hyper-V guests on this server, one is another Server 2012 R2 Standard instance (which will be a terminal server) and the other is SBS2011.  The host server does nothing except run these two hyper-v guests.

I'm trying to understand the best way to set up the CPU allocation to these guests and am confused about the "sockets" and NUMA stuff.  The host system effectively has 8 cores in total.  Should I set both guests to use 8 sockets?  Currently they are both set to use 4 sockets, but i am concerned I may not be using all the hosts resources.

Once that is worked out, should i play with any reserve values, or just let hyper-v manage it unless i encounter an issue?

thanks in advance!
nathan
0
natrat22
Asked:
natrat22
  • 4
  • 3
  • 3
2 Solutions
 
Philip ElderTechnical Architect - HA/Compute/StorageCommented:
We would assign # Cores - 1 vCPUs to SBS 2011 Standard. 16GB vRAM to 24GB vRAM depending on user count.
We would assign 4 vCPUs to the R2 Standard for RDS. 2GB vRAM + 512MB/User for RDS.

RAID 6 across 10K SAS spindles with a minimum of 6 but preferably 8 would be a good place to start. Hardware RAID with battery backed or non-volatile cache.

You have one more license to use for virtualizing another guest based on the host (1+2).

Philip
0
 
natrat22Author Commented:
Hi Philip, thanks for your reply, I'm a big fan and read a lot of your stuff on third tier and elsewhere :)

Did you mean 3 cores - 1 vCPU in the first line?  I'm confused as to how to do that in Hyper-V.  The options on the main settings section is simply "Number of virtual processors".  No reference to cores.  the screenshots attached show the current settings.
Capture.JPG
Capture2.JPG
0
 
Philip ElderTechnical Architect - HA/Compute/StorageCommented:
To the CPU a virtual CPU (vCPU) = 1 thread.

As a rule one thread runs through the pipeline via one physical core on the CPU (with some shenanigans presented by Hyper-Threading).

So, what we do is take the number of physical cores - 1 to set maximum number of vCPUs assigned to a VM. So, in your case we would assign a maximum of 3 vCPUs to a VM.

NUMA and memory assignment has to do with available RAM attached to a specific CPU. If that RAM is relatively full and a VM comes online that requires more RAM than available at that CPU its vRAM is shuffled over to RAM associated with another CPU. This shuffle costs CPU cycles.

In my experience when the processing logic has to shuffle vCPU threads between CPUs (they _have_ to be processed parallel in the pipeline) or RAM between CPUs performance gets compromised during those shuffle cycles.

Philip
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
Jeffrey Kane - TechSoEasyPrincipal ConsultantCommented:
One thing I notice from your screen shots is that you only have about 14GB of RAM allocated to your SBS.  You may find that is not enough (depends on how many users, and other factors) so I would keep an eye on the performance of the SBS and increase the RAM if you are having issues.

Be aware though, as Philip alluded to above, RAM is attached to a specific CPU.  I've found that it's best to keep amount of RAM balanced, so if you currently have 32GB of RAM in the server (16GB in each bank), add RAM to both sides if you add any at all.

These days, the cost of RAM is plenty low enough compared to the additional performance you get -- having plenty in place generally avoids needing to even worry about the allocation you are asking about.
0
 
natrat22Author Commented:
Its a small small business :)   Around 10 users - I've been running SBS2011 with 12GB RAM for businesses of that size on physical hardware without any issues for a while so I figured 14 would be plenty for the VM.  I also do some memory tweaks on all my SBS installs - setting a max RAM use for exchange store for example, which just runs rampant otherwise.

I did originally try to add 14GB to each VM but it said there wasnt enough RAM, even though there is 32GB in the system.  I've yet to investigate that, I'm sure theres some way to sort that out.
0
 
natrat22Author Commented:
Philip i hadn't seen anywhere in my searching a reference to using physical cores minus 1 for vCPU allocation.  Whats the logic behind this?  Is it effectively keeping a core free for the host?
0
 
Jeffrey Kane - TechSoEasyPrincipal ConsultantCommented:
If you've been running fine with 12GB, then definitely you will be okay with 14GB for your VM.

The reason you may have had trouble assigning 14GB to each VM is related to what Philip said about NUMA above.  Your machine may have 32GB, but there are only 16GB per processor.  If you assign the VM to a specific processor then it will only have 16GB available and if your host is taking up a couple, then it won't have quite enough to give you 14GB.

This is why in a small environment, I generally just let Hyper-V handle things in the default manner.  Because with only 10 users, I doubt you will experience any performance issues which would require you to do any additional fine tuning.
0
 
natrat22Author Commented:
Thanks, but i did just let hyper-v do everything.  I set up the first VM with 14GB, and all other settings default.  then I tried to set up another VM with 14GB and it wouldnt let me do it, hence dropping it back to 12.  As I said I'm sure there is a way to fix that, i just haven't got around to researching it yet :)
0
 
Jeffrey Kane - TechSoEasyPrincipal ConsultantCommented:
I just explained above why you couldn't do it... what more do you need to research?
0
 
Philip ElderTechnical Architect - HA/Compute/StorageCommented:
Our practice of #Cores - 1 for total vCPUs comes from a few things.

One was a Hyper-V performance discussion via TechEd about 5 years ago that is no longer available. In that discussion we learned that the CPU pipeline must process VM threads (vCPUs) in parallel through the entire pipeline (CLOCK_WATCHDOG_TIMEOUT was the result of threads getting out of sync blog post).

Also in that discussion was how the pipeline juggles the various thread sets for each VM.

Essentially, the CPU pipeline scheduler has a little more room to work when there is at least one core available.

Philip
0

Featured Post

Restore individual SQL databases with ease

Veeam Explorer for Microsoft SQL Server delivers an easy-to-use, wizard-driven interface for restoring your databases from a backup. No expert SQL background required. Web interface provides a complete view of all available SQL databases to simplify the recovery of lost database

  • 4
  • 3
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now