VMware Cloud Community
TylerDurden77
Enthusiast
Enthusiast
Jump to solution

High cpu usage on newly created 5.5 vcenter (build 1623101)

Hi Admins!

I dont understand why my newly created vcenter use to much cpu resources.

Java(TM) Platform Binary uses 50% of cpu resources

Environment:

6 ESX hosts (5.5)

1 virtual vcenter (5.5)

150 VMs

My vcenter server is running as a VM (win2012r2) configured with 4 vcpus ( Our old vcenter had 2 vcpus and had no issues)

Vanilla install

Any advice how i should tackle this?

Cheers

Tylor

vc.PNG

1 Solution

Accepted Solutions
angelomk
Contributor
Contributor
Jump to solution

TylerDurden77 Try to tweak the Java heap size for the vCenter services, especially for the Inventory Service. Default value is 3GB.

Hereby useful links with more details:

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=202130...

Tweaking Java.exe memory usage on vCenter Server 5.1 « Default Reasoning

After the change you need to restart the services.

Even if those parameters in general affect the memory usage, they can help reducing the CPU consumption.

Br,

Angel

View solution in original post

0 Kudos
6 Replies
TylerDurden77
Enthusiast
Enthusiast
Jump to solution

So the crook seems to be the vmware inventory service.

When i stopped it cpu went drastically down.

Is it normal that the inventory service uses this much cpu?

Regards

tylor

inv.PNG

0 Kudos
angelomk
Contributor
Contributor
Jump to solution

TylerDurden77 Try to tweak the Java heap size for the vCenter services, especially for the Inventory Service. Default value is 3GB.

Hereby useful links with more details:

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=202130...

Tweaking Java.exe memory usage on vCenter Server 5.1 « Default Reasoning

After the change you need to restart the services.

Even if those parameters in general affect the memory usage, they can help reducing the CPU consumption.

Br,

Angel

0 Kudos
TylerDurden77
Enthusiast
Enthusiast
Jump to solution

Hi Angel,

Thanks for ur reply!

I have been on vacation thats why i havent responded until now.

I just changed the "wrapper.java.maxmemory" to 1024mb ,

Will get back with info if this solves my cpu issues.

Cheers

Johan

0 Kudos
TylerDurden77
Enthusiast
Enthusiast
Jump to solution

Thanks Angel!

Tweaking java seems to have solved my issue.

Many thanks!

Regards,

Tyler

mowgus
Enthusiast
Enthusiast
Jump to solution

This might come in handy for admins using vCenter 6. 

vCenter 6 now has dynamically adjusting heap size.  It essentially looks at how much RAM you have allocated to your vCenter system and then allocates RAM accordingly to pretty much use up all available RAM for the java processes.  Great for large environments as when you increase the RAM in your vCenter OS, it will sense that on reboot and assign more RAM to processes.  What I don't like about it is in an environment where there's only 2 or 3 hosts (lab or small company) it uses all of the 8 GB of RAM allocated to vCenter regardless as to whether or not it's needed.  This can be wasteful in a small environment with limited resources on the host.

After some poking around I found out there is a command to set custom sizes for the dynamic tool.  Let me preface this by saying I highly doubt it's supported and would suggest it's a bad idea to do this in a production environment without VMware telling you to but, for lab purposes, it could come in handy.

Change to the following directory in order to run the command:  c:\Program Files\VMware\vCenter Server\visl-integration\usr\sbin (or whatever the path is on your system)

cloudvm-ram-size -l     

will list memory size to be allocated to processes

cloudvm-ram-size -S

will list current memory allocated to processes

What it doesn't tell you is how to customize the setting (likely because VMware doesn't want you screwing with it)

cloudvm-ram-size -C ### {processname}

will set a customMB size for the particular service. 

This is reflected in the following file: c:\ProgramData\VMware\vCenterServer\cfg\service-layout.mfx.   The customMB column will be populated with the custom settings and used on boot.  I've noticed that I had to use the ciswin_name for the process on my Windows system when running the cloudvm-ram-size -C command. 

ryantodd
Contributor
Contributor
Jump to solution

FYI, the comments in the service-layout.mfx are incorrect. The check for the settings should be:


$ awk '!/^#/{t+=$5;l+=$6;p+=$7;print}END{print t,l,p;print t+p,l+p}' service-layout.mfx

They were specifying 6,7,8 for the columns. The above should make it so that:

# sum(tinyMB) + sum(MaxPermMB) = 8000

# sum(largeMB) + sum(MaxPermMB) = 32000

No idea what impact if at all setting the customMB has on this figuring though...

0 Kudos