Configure the OpsCenter JVM
The OpsCenter JVM is tuned to handle both large and small clusters with initial memory and garbage collection JVM parameters. These default values should be sufficient for most users. However, certain scenarios can arise that might require you to further tune these parameters.
To configure the OpsCenter JVM, do the following:
-
Edit the
opscenterscript for your OpsCenter installation:-
Package installations:
/usr/share/opscenter/bin/opscenter -
Tarball installations:
INSTALL_DIRECTORY/bin/opscenter
-
-
Find the line beginning with
OPSC_JVM_OPTS:in theopscenterscript, and then modify the JVM parameters as needed.For example:
OPSC_JVM_OPTS="-server -Xmx2048m -Xms1024m -Dpython.cachedir.skip=false -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=$OPSC_LOG_PATH -XX:+UseG1GC -XX:MaxGCPauseMillis=200 -XX:G1ReservePercent=0 -XX:ParallelGCThreads=4 -XX:ConcGCThreads=4 $GC_OPTIONS $OPSC_JVM_OPTS"For example:
-
-Xmx: The maximum amount of heap space available foropscenterdto use. This default is2048m(2 GB), which should be enough for most installations. When you are managing multiple clusters or you see OutOfMemory errors inopscenterd.log, try doubling the heap size to4096m(4 GB). If memory-related issues continue, contact IBM Support. -
-Xms: The initial amount of heap space that theopscenterdprocess uses on startup. Lower this value ifopscenterdis having trouble starting. Alternatively, setting this value to match-Xmxwill prevent the JVM from dynamically resizing the heap, thus reducing performance overhead. -
Do not modify Garbage Collection parameters for Java. However, if there is a need to modify and tune other garbage collection parameters, follow the Garbage Collection Tuning Guide for Java 8 or Java 9.
-
-Djava.io.tmpdir=/path/to/dir: The directory that Jython uses to load and execute dynamic classes (default is the systemtmpdirectory). Change this to another directory if you are having trouble loading OpsCenter due to permissions on the default directory.
-
-
Edit the
opscenterscript directly, while OpsCenter is running or not. -
sudo service opscenterd restartYou must restart OpsCenter any time you change these JVM parameters.