Solved

CPU for vmware

Posted on 2013-06-23
12
557 Views
Last Modified: 2013-06-28
Hi _ I have an infrequent problem CPU  for java.exe hits %99.

Its a VM - Windows shows as 4 CPU's in device manager

for the VM I have 4 sockets and 1 core per socket. Is this the right config. - I see conflicting info on the web. - Can someone advise on best CPU VM setup.

see attach of CPU in vcentre client
Capture.PNG
0
Comment
Question by:philb19
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
12 Comments
 
LVL 6

Expert Comment

by:Vijay Pratap Singh
ID: 39270219
Try to go with 4 CPU's with 2 core per CPU it will definitely reduce some load.
0
 

Author Comment

by:philb19
ID: 39270225
So thats 4 sockets (which I already have ) and change 1 core to 2 ?
0
 
LVL 23

Expert Comment

by:Nagendra Pratap Singh
ID: 39270240
Best is one vcpu.
0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 

Author Comment

by:philb19
ID: 39270250
Sorry again confused. :(   So 1 vcpu is 1 socket?

how many core then?
0
 
LVL 23

Expert Comment

by:Nagendra Pratap Singh
ID: 39270322
1 x1

If you have a wide VM ( with many cores ) then it has to wait till the path is wider .

If you have 8 physical CPUs (pcpu) and 2 VMs of 4 vcpu + 1 single vcpu machine then the heavy machines will be slowed down.

Total needs to be <=8 in this case

One site to explain this. Others I will find when I come back.

http://www.virtualinstruments.com/ipm-blog/best-practices/avoiding-the-virtual-cpu-dilemma-overprovisioning-vcpu-to-pcpu-ratios/

another

http://www.gabesvirtualworld.com/how-too-many-vcpus-can-negatively-affect-your-performance/
0
 
LVL 1

Expert Comment

by:NAMEWITHELD12
ID: 39270328
is the assumption that correcting the CPU type is going to correct the problem?

is there a java app that is running on the guest that is doing this ?

is the problem something RUNNING ON THE GUEST?
0
 

Author Comment

by:philb19
ID: 39270338
Sorry from what I have 4 sockets and 1 core. - What do you recommend changing this to?

npsingh123  

should i chnage to 1 socket 4 cores?
0
 
LVL 23

Expert Comment

by:Nagendra Pratap Singh
ID: 39270357
1 socket 1 core.

the cpu usage also depends on the app and the load.
0
 
LVL 23

Expert Comment

by:Nagendra Pratap Singh
ID: 39270358
also install vmtools.
0
 
LVL 19

Expert Comment

by:vmwarun - Arun
ID: 39270384
Ideally, the number of vCPUs allocated to a VM depends on the actual CPU requirement. Just because a physical server had a quad core CPU doesn't justify allocating 4 vCPUs when it is converted to a VM. Check if the VM has a CPU ready value in the performance graphs. CPU ready shows the time a VM has to wait for CPU cycles to be scheduled on the physical hardware layer. The lesser the value, the better it is.
0
 
LVL 120

Accepted Solution

by:
Andrew Hancock (VMware vExpert / EE MVE^2) earned 500 total points
ID: 39270474
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
http://www.vmware.com/resources/techresources/10131

see here
http://www.gabesvirtualworld.com/how-too-many-vcpus-can-negatively-affect-your-performance/

http://www.zdnet.com/virtual-cpus-the-overprovisioning-penalty-of-vcpu-to-pcpu-ratios-4010025185/

also there is a document here about the CPU scheduler

www.vmware.com/files/pdf/perf-vsphere-cpu_scheduler.pdf
0
 
LVL 55

Expert Comment

by:andyalder
ID: 39270757
As far as I understand the no of virtual sockets and cores per socket doesn't make any difference assuming the total number of vCPUs is the same. If it was physical sockets then for speed you would want everything on the same CPU but it's virtual so although VMware tells the guest there are 4 CPUs with one core each it may actually be running on a single CPU.

On the Java side 100% CPU may be down to a looping process so giving it more resources just allows it to go around the same useless loop faster. There's a troubleshooting guide at http://javaeesupportpatterns.blogspot.co.uk/2012/05/java-high-cpu-troubleshooting-guide.html but not much help unless it's a Java app that you wrote yourself.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Migrate VM to other host 12 99
Hit router interface limit 7 66
vSphere Clustering DRS 3 56
RDM/VMFS5  limitation in vSphere 6.0 1 28
Will try to explain how to use the VMware feature TAGs in the VMs and create Veeam Backup Jobs using TAGs. Since this article is too long, I will create second article for the Veeam tasks.
In this article we will learn how to backup a VMware farm using Nakivo Backup & Replication. In this tutorial we will install the software on a Windows 2012 R2 Server.
Teach the user how to use vSphere Update Manager to update the VMware Tools and virtual machine hardware version Open vSphere Client: Review manual processes for updating VMware Tools and virtual hardware versions: Create a new baseline group in vSp…
This Micro Tutorial steps you through the configuration steps to configure your ESXi host Management Network settings and test the management network, ensure the host is recognized by the DNS Server, configure a new password, and the troubleshooting…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question