Link to home
Start Free TrialLog in
Avatar of Hodor
HodorFlag for United States of America

asked on

Server 2012 Hyper-V best practices to max out performance

Currently I have a Server 2008 R2 Datacenter with about 20 VMs. One of the biggest bonuses of upgrading to Server 2012 is the ability to give each VM more then four cores. My question would be if the host server has 24 cores and 20 VMs need cores would I need to split the cores among the the 20 VMs or can each server get assigned 10 cores each? I want to get the best out of the servers especially our RDS servers which get about 10 people per server on them.
Avatar of Lee W, MVP
Lee W, MVP
Flag of United States of America image

You should probably be looking to REDUCE cores and not increase them.

VM performance can DECREASE with additional cores due to thread scheduling issues with multiple CPUs and VMs.

http://www.stratogen.net/blog/poor-virtual-machine-performance-with-multiple-cpus/
Avatar of Hodor

ASKER

So anything higher than 2 cores on a Windows machine can be counter productive. Does this also mean that cores should only be assigned to the amount of cores available...24 cores then only 12 virtual machines should be running.

Anything need to be allocated for the host, nothing really runs on the host beside the VMs?
Actually, a single core is ideal... if you need more you can use more, but be wary of performance issues.  As I understand it, the VM cannot execute a single thread until a sufficient number of CPUs are available for that VM to have all allocated processors execute.  This can slow things down.  With a single CPU assigned, there is virtually no waiting... with multiple CPUs - even two - it COULD increase the wait time.

Honestly, I'd heard of this before but not in great detail and I'm just learning about it myself... but before you go assigning a large number of CPUs to a VM, you should learn more about the potential consequences of doing so - I'm trying to.
An RDS farm with 10 users per RDSH? You could get away with 2 vCPUs and 4GB of vRAM, maybe 6GB, per VM.

Is there an app running on RDSH that requires multithreading or lots of CPU cycles?

Typically one can assign about 256MB to 512MB per user for an RDSH setup. This all depends on the apps being run.

We find the bottleneck tends to be in the disk subsystem though not in CPU.

I have an EE article here that may help: Some Hyper-V Hardware and Software Best Practices.
Avatar of Hodor

ASKER

This weekend I will change 4 out of the 5 RDS servers to use 2 vCPUs and reduce the vRAM. I will then compare the performance of the 4 to the 1 server I left with 4 vCPUs.

We are looking to upgrade our hosts and in the article Philip Elder sent it recommends going for Ghz over more cores. It counter intuitive so is there a reason for this recommendation?
If you can have a highway with six lanes running at 150KMH or eight lanes running at 110KMH which would be more efficient?

The catch is _always_ in the apps being hosted. Most end-user facing apps are single threaded. That means that they would only use one vCPU for their process.

The faster the core setup the faster those single threads can get through the CPU pipeline.

Workloads such as SQL and rendering farms are two that come to mind that require lots of cores. Virtualizing them without testing their performance in a virtual setting could end up being a painful experience.
Avatar of Hodor

ASKER

150KMH on 6 lanes does sound better.

I have researched most of the applications we use and they are all single threaded. Now this make sense to reduce the cores to one but factoring in an average of 10 users per RDSH does it still make sense?
For any given RDSH single/farm we'd be setting a minimum of 2 vCPUs for each RDSH VM. This allows for one OS thread and one client thread to be processed in-VM together.

For the physical CPU this means processing two simultaneous threads which is a lot easier to get through the CPU pipeline than say 4 threads (4 vCPUs in VM) or 6 threads (6 vCPUs in VM).

There's a balancing act that needs to happen for performance in a virtual setting. The number of vCPUs and the amount of vRAM play a huge part in the actual in-VM experience.
ASKER CERTIFIED SOLUTION
Avatar of Hodor
Hodor
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Not sure this question should be closed with no points awarded?

Flesh out the results please. How many cores yielded the best results?
Avatar of Hodor

ASKER

Heard great feedback, actual testing provided a different result then expected.