Solved

CPU for vmware

Posted on 2013-06-23
12
559 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 24

Expert Comment

by:Nagendra Pratap Singh
ID: 39270240
Best is one vcpu.
0
Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

 

Author Comment

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

how many core then?
0
 
LVL 24

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 24

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 24

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 121

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

What Is Transaction Monitoring and who needs it?

Synthetic Transaction Monitoring that you need for the day to day, which ensures your business website keeps running optimally, and that there is no downtime to impact your customer experience.

Question has a verified solution.

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

Last article we focus in how to VMware: How to create and use VMs TAGs – Part 1 so before follow this article and perform the next tasks, you should read the first article how to create the TAG before using them in Veeam Backup Jobs.
In this article, I will show you HOW TO: Install VMware Tools for Windows on a VMware Windows virtual machine on a VMware vSphere Hypervisor 6.5 (ESXi 6.5) Host Server, using the VMware Host Client. The virtual machine has Windows Server 2016 instal…
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…
This video shows you how to use a vSphere client to connect to your ESX host as the root user. Demonstrates the basic connection of bypassing certification set up. Demonstrates how to access the traditional view to begin managing your virtual mac…

729 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