Jump to: navigation, search

Tuning Your JVM

Web Engagement Server allows you to tune your JVM parameters, which is especially important with respect to the virtual memory allocated to the JVM. You can modify your JVM parameters in the setenv.bat or setenv.sh file that is located at Web Engagement installation directory\server\.

Tuning Your Memory Allocation

Out of the box, the setenv.bat and setenv.sh files have the following memory settings:

set MEMORY_MIN=4096m
set MEMORY_MAX=4096m

If you want to change these settings, update the appropriate values and restart the Web Engagement Server.

Note: In older versions of GWE, memory management in setenv.bat and setenv.sh files was done explicitly through the Xms and Xmx parameters:

-Xms512m -Xmx1024m -XX:MaxPermSize=250m

Therefore, if you are using an older version of GWE, correct these parameters instead of MEMORY_MIN and MEMORY_MAX.

Enabling the JMX Port

You can monitor the JVM where your Web Engagement Server is running by using some of the standard Java tools distributed with the JDK, such as JConsole or Visual VM. Since these tools work through the JMX port, the Web Engagement Server needs to open this port on startup.

Out of the box, the setenv.bat and setenv.sh files contain all of the settings you need to turn on JMX access. Here's what setenv.sh looks like:

:: Uncomment to enable JMX Remote
:: set JMX_PORT=7199
:: set JAVA_OPTS=%JAVA_OPTS% -Dcom.sun.management.jmxremote ^
:: -Dcom.sun.management.jmxremote.port=%JMX_PORT% ^
:: -Dcom.sun.management.jmxremote.local.only=false ^
:: -Dcom.sun.management.jmxremote.ssl=false ^
:: -Dcom.sun.management.jmxremote.authenticate=false

As you can see, the JMX parameters are turned off by default. To enable JMX access, you need to uncomment these settings.

Note: Opening the JMX port without adequate security can be risky. See the JMX monitoring and management documentation for information about how to tune your security settings when using JMX to monitor your JVM.

Applying Parameters to Your Windows Service

It is important to understand that any changes you make to the setenv.bat file will not be applied to the Windows service that starts Web Engagement Server. Here's how to apply the parameters from setenv.bat to your Windows service:

  1. Make all necessary changes to setenv.bat.
  2. Ensure that your Web Engagement Server can be started successfully from the command line.
  3. Execute the server.bat remove command to remove your existing Windows service.
  4. Execute the server.bat install command to install a new Windows service.

After you finish these steps, your Windows service will be synchronized with server.bat.

This page was last modified on February 1, 2019, at 14:26.


Comment on this article:

blog comments powered by Disqus