Installation - Startup Parameters for Java Agent on an Open Liberty Application Server


Open Liberty Compatibility

vFunction supports Open Liberty version 21 and later.


Installation Workflow

  1. Install the Dynamic Analysis Controller
  2. Find and note the base path to your Open Liberty Application Server

    ### This should return the location of the Open Liberty's SERVER_CONFIG_DIR

    find / -name 'server.xml' -type f
  3. Add the startup parameters to your Open Liberty Application Server's jvm.options:

    ### Replace the INSTANCE_NAME and SERVER_CONFIG_DIR below with the actual value

    cat etc/sysconfig/vfunction/agent/instances/INSTANCE_NAME/vmargs-examples/liberty >> SERVER_CONFIG_DIR/jvm.options
  4. Restart the Open Liberty instance
  5. Confirm that the Application comes up and functions as expected
  6. If any issues arise:

Sample contents of vmargs-example/liberty file

If using this sample below, you will need to:

  1. Find-and-replace the REPLACE_BASE_DIR with the value relevant to your vFunction installation
  2. Find-and-replace the REPLACE_INSTANCE with the value relevant to your vFunction installation

This sample file exists in the Installation TGZ in /opt/vfunction/controller-installation/stuff/agent/vmargs-examples/java/liberty. Once the install.sh script is run, the relevant placeholder fields are replaced in the version of the environmentally-specific file in /etc/sysconfig/vfunction/agent/instances/INSTANCE_NAME/liberty.

Sudo Installation Sample
# Create file <wlp>/usr/servers/<your-server>/jvm.options and add the following lines:

-agentpath:REPLACE_BASE_DIR/opt/vfunction/agent/libJVMTIAgent.so
-javaagent:REPLACE_BASE_DIR/opt/vfunction/agent/runtime-agent.jar
-Dcom.vfunction.instance=REPLACE_INSTANCE
Sudoless Installation Sample
# Create file <wlp>/usr/servers/<your-server>/jvm.options and add the following lines:

-agentpath:REPLACE_BASE_DIR/opt/vfunction/agent/libJVMTIAgent.so=conf=REPLACE_BASE_DIR/etc/sysconfig/vfunction/agent/instances/REPLACE_INSTANCE/native-conf.json
-javaagent:REPLACE_BASE_DIR/opt/vfunction/agent/runtime-agent.jar=ConfigLocation=REPLACE_BASE_DIR/etc/sysconfig/vfunction/agent/instances/REPLACE_INSTANCE/vfunction-runtime-override.properties
-Dcom.vfunction.runtime.shared.folder=REPLACE_BASE_DIR/opt/vfunction/controller/instances/REPLACE_INSTANCE/temp/
-Dcom.vfunction.runtime.offload.tmpFolder=REPLACE_BASE_DIR/opt/vfunction/agent/instances/REPLACE_INSTANCE/temp/
-Dcom.vfunction.logging.logFile=REPLACE_BASE_DIR/var/log/vfunction/instances/REPLACE_INSTANCE/vfagent.log