Creating VMware Virtual Servers CPU

I'm creating a new Server 2012 Windows server and have a question about the CPU setting.  

I'm using VMware and need to create a server with 12 cores.   When prompted for the CPU I'm given both a " Number of Virtual Sockets" and " Number of Cores per socket " .....    

I don't totally understand these values and need a bit of help setting them.      

Thanks ...

Joel BrownIT DirectorAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Jose Gabriel Ortega CastroCEOCommented:
I think that the best answer is this one:
In VMWare does not make a difference.  It is purely based on how the CPU's are presented to the guest.  Whether you choose dual sockets single core each, or single socket with dual-core, VMWare treats those as the same, you get 2 cores of CPU time.

The main reason this was added was for software licensing on the guests.  In our case, our SQL server has a single processor license.  If I want to allocate 4 cores and I use the default of 4 sockets single core each, then I am in violation of my SQL license, because that is 4 sockets.  If I change that to a single processor with 4 cores, then I am legal again.  I get the same performance in VMWare either way.

Microsoft has already announced that many of their new versions of the software will be on a per core license model, such as the new version of SQL Server.


Also, there's an analytic answer about it here:
Qlemo"Batchelor", Developer and EE Topic AdvisorCommented:
As a rule of thumb, use virtual sockets if you software (e.g. OS) does explicitely asks for cores. Some softeare is optimized for using multiple cores, but most don't care, and then sockets is the best approach. VMware is able to map virtual sockets to real cores best, while choosing multiple cores forces VMware to mirror exactly that, reducing the ability to optimize itself.

In theory, sockets are considered to operate independently from each other, only sharing external resources (physical memory, memory bus). Cores are sharing some parts of the processor, like cache and internal memory bus, and some logic units, so two cores can compete over resources sockets do not have to, while having faster access to some common resources.
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
Use the DEFAULT, which is assign virtual sockets (vCPU) not Cores, unless you have a specific licensing requirement to use cores.

The Default to assign sockets is best. Now assigning 12 CPUs to a VM, could be overkill, what is the application ? Often a requirement is based on a physical server requirement, not a virtual server.

vSMP (virtual SMP) can affect virtual machine performance, when adding too many vCPUs to virtual machines that cannot use the vCPUs effectly, e.g. Servers than can use vSMP correctly :- SQL Server, Exchange Server.

This is true, many VMware Administrators, think adding lots of processors, will increase performance - wrong! (and because they can, they just go silly!). Sometimes there is confusion between cores and processors. But what we are adding is additional processors in the virtual machine.

So 4 vCPU, to the VM is a 4 Way SMP (Quad Processor Server), if you have Enterprise Plus license you can add 8, (and only if you have the correct OS License will the OS recognise them all).

If applications, can take advantage e.g. Exchange, SQL, adding additional processors, can/may increase performance.

So usual rule of thumb is try 1 vCPU, then try 2 vCPU, knock back to 1 vCPU if performance is affected. and only use vSMP if the VM can take advantage.

Example, VM with 4 vCPUs allocated!

My simple laymans explaination of the "scheduler!"

As you have assigned 4 vCPUs, to this VM, the VMware scheulder, has to wait until 4 cores are free and available, to do this, it has to pause the first cores, until the 4th is available, during this timeframe, the paused cores are not available for processes, this is my simplistic view, but bottom line is adding more vCPUs to a VM, may not give you the performance benefits you think, unless the VM, it's applications are optimised for additional vCPUs.

See here

see here

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

Qlemo"Batchelor", Developer and EE Topic AdvisorCommented:
This is true, many VMware Administrators, think adding lots of processors, will increase performance - wrong!
There is much truth in that. Imagine a machine running a single-threaded high-cpu process. With one processor, it can use 100% CPU. With two 50%, aso. No performance gain in regard to this single process. However, with a two+ CPU VM other processes can still run well if the high-CPU process goes full steam ahead.
Joel BrownIT DirectorAuthor Commented:
I will be installing Sql 2016 standard on this server using the server/user cal licensing model.   The software running on the server will require 12 cores ........
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
How many concurrent users will use the database ?

Does your host have dual processors ?
Qlemo"Batchelor", Developer and EE Topic AdvisorCommented:
Sounds horribly oversized, but so be it. Just use sockets to get the best result - provided you can assign that much and they are recognized by the OS.
Joel BrownIT DirectorAuthor Commented:
@ Andrew,     At most we will have 50 concurrent users connected to the database ....    The servers have 2 each of PROCESSOR, X5650, 2.66/6.4, 12MB, XWM, B1 .......

Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
That's not many...I would refer to this document, to architect your SQL VM...

those are quite old HOST processors...check ESXi is supported and on HCL.

Architecting Microsoft SQL Server on VMware vSphere

Getting SQL Servers to perform well under a hypervisor - vSphere or Hyper-V - can be tricky and just throwing processors at it, sometimes may not be the best thing. Memory and Datastore IOPS is criticial!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Virtual Server

From novice to tech pro — start learning today.