VMWare ESXi Guest CPU

Im trying to understand when I build the VMware Guest server.

If the guest requirement for processor is 1 dual core or 1 quad core,
What do I set for the (number of virtual sockets and number of cores per socket)?

Please advise.
Thank you
CollinMendozaIT DirectorAsked:
Who is Participating?
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.

JohnBusiness Consultant (Owner)Commented:
I set dual core and 1 CPU in the example above.
Andrew Hancock (VMware vExpert / EE Fellow)VMware and Virtualization ConsultantCommented:
Always use Sockets, and not Cores, unless you have a specific - per Core license agreement.

VMware vSphere (if you are using vSphere) by default always suggests the best specification for your VM.

What you need to workout, is how many CPUs your Guest requires.

1 vCPU, 2 vCPU.

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


also there is a document here about the CPU scheduler



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
CollinMendozaIT DirectorAuthor Commented:
Andrew, Great info. Thank you.
CEOs need to know what they should worry about

Nearly every week during the past few years has featured a headline about the latest data breach, malware attack, ransomware demand, or unrecoverable corporate data loss. Those stories are frequently followed by news that the CEOs at those companies were forced to resign.

Andrew Hancock (VMware vExpert / EE Fellow)VMware and Virtualization ConsultantCommented:
No problems, if you still need help, related to vCPU (virtual CPUs) in a VM, please ask, because it is a very misunderstood subject.

and often, you may need to allocate as many as 8 vCPUs, for the correct performance, and application.
CollinMendozaIT DirectorAuthor Commented:
I know it s bit confusing. so if I understand this...

the requirement is "1 dual core or 1 quad core" for SQL server.

so for my VMware guest, I set the "number of virtual socket" equal to 2(dual) or 4(quad" and the "number of cores per socket" equal to 1.

Is this correct?
Andrew Hancock (VMware vExpert / EE Fellow)VMware and Virtualization ConsultantCommented:
Yes, always use Sockets.

Unless you have a license restriction and need to use Cores, that's why it was invented.

It's really not as straight forward as that, unless those requirements are based on virtual requirements, or are just based in the physical world.

Because a Dual Core Physical Processor (bare metal server) may not really equate to a Virtual Machine just with 2 Sockets (vCPUs).

the same is true of a requirement for 4 sockets (vCPUs).

I would recommend, you try 2/4 sockets, check performance, are you experiencing a CPU bottleneck, slowness which can be attributed to CPU, and increase.
CollinMendozaIT DirectorAuthor Commented:
Ok. sounds good. Thank you for the feedback.
Andrew Hancock (VMware vExpert / EE Fellow)VMware and Virtualization ConsultantCommented:
not a problem.
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

From novice to tech pro — start learning today.