2011-06-26

Reducing the amount of RAM for vCenter Orchestrator

****** Disclaimer *****
This is not recommended by VMware and I am also pretty sure it is not supported either, so if you make this change then do so at your own risk.

The vCenter Orchestrator Installation and Configuration Guide states the following for Hardware requirements.

Hardware requirements

A few pages later this statement is also made.

Guidelines

I actually find this quite strange because Orchestrator is installed by default on each and every instance of vCenter Server. You are able to install this separately from the following location from the vCenter package.

Location

It can be removed from the vCenter after the default installation, if you would like.

Add/Remove

But when you are using a lab, just to put up another VM to run Orchestrator is a waste of resources. But one of the problems is you will run into is memory.

Running a vCenter server can demand a lot or resources. as per the ESX and vCenter Server Installation Guide 

Minimum Requirements:

vCenter Minimum

Medium Size:

vCenter Medium

And all of this if you are not running the database server locally on the vCenter Server.

But what happens when you start up vCenter Orchestrator?

Here is a screenshot of my vCenter Server (Database is located on a separate server) before I started Orchestrator, utilizing just under 50% of the RAM.

Before Orchestrator

Starting Orchestrator brought the RAM up to ~75%

Started Orchestrator

But what I found worrisome was actually the amount of committed KB

Resource Monitor

Where did this come from - well that was actually pretty simple. The command that started the Orchestrator process was as below

Command path

Those numbers looked pretty similar. But what is Xms and Xmx - Google led me here.

-Xms initial java heap size
-Xmx maximum java heap size

For Orchestrator these were defined as 2048m (2GB) for each.

As per Enterprise Java Applications on VMware - Best Practices Guide, sizing the right amount of RAM for a VM with Java Applications 

VM Memory (needed) = guest OS memory + JVM Memory,
JVM Memory = JVM Max Heap (-Xmx value) + Perm Gen (-XX:MaxPermSize) + NumberOfConcurrentThreads * (-Xss)

In vOrchestrator's case :

VM Memory (needed) = 4GB (Guest OS) + 2GB (-Xmx Value) + 256MB (MaxPermSize) + 256k (Xss) = 6.25GB

Which is a bit steep - IMHO.

The heap size is set by default to 2GB. Is this necessary? For a fully production environment - perhaps, for a small lab - I doubt it.

And where was this setting applied? The configuration is located by default here:

C:\Program Files\VMware\Infrastructure\Orchestrator\app-server\bin\wrapper.conf

To change the amount of RAM for the process:

Stop Orchestrator and edit the above file and make the following changes:

# Initial Java Heap Size (in MB)
wrapper.java.initmemory=2048 1024

# Maximum Java Heap Size (in MB)
wrapper.java.maxmemory=2048 1024

Restart Orchestrator.

And this is what the Heap size looked like

After modification

1GB less and fully functional.

One more time - this is not supported and can be used in your Lab environment if you are short on RAM.

During all the experiments - I got Orchestrator running with under 768MB of RAM. Just because I could..