Skip to main content
Version: 25.0.0

GlassFish

Please refer to the Waratek Proposed Directory Structure section in this document for assistance with the steps below.

Basic Configurations

  1. Go to <absolute-path-to-glassfish>/glassfish/domains/<domain-name>/config folder.

  2. Open the domain.xml file.

  3. Add the JVM options as follows. The property file can use any name, for the example below we will name this waratek.properties, we will also assume that this references the first available configuration directory i.e. /opt/waratek/conf_1

    1. On Linux:
<jvm-options>-javaagent:/opt/waratek/agent/waratek.jar</jvm-options>
<jvm-options>-Dcom.waratek.WaratekProperties=/opt/waratek/conf_1/waratek.properties</jvm-options>
  1. On Windows:
<jvm-options><absolute-path-to-waratek-software>\agent\waratek.jar</jvm-options>
<jvm-options>-Dcom.waratek.WaratekProperties=<absolute-path-to-waratek-software>\conf_1\waratek.properties</jvm-options>
  1. Optional : Verify the content of the domain.xml file by the verify-domain-xml command.
asadmin> verify-domain-xml
asadmin> All Tests Passed. domain.xml is valid
  1. If the GlassFish server supports dynamic configuration changes, the changes take effect while the server is running and you do not need to restart the server. Otherwise, the server must be restarted for the changes to take effect.
  2. On Linux, locate the asadmin(usually located in glassfish/bin folder of Glassfish), and run with the start flag
asadmin start-domain <domain name>