Installation - Startup Parameters for Java Agent on a SpringBoot Installation
Installation Wizard
To help with the installation process, vFunction offers an Installation Wizard. This Wizard provides additional information about the Prerequisites as well as steps for deploying the vFunction Agent to your environment.
Please contact support@vfunction.com or your vFunction Contact(s) for the password to start using this Wizard.
Installation Steps
- Install the Dynamic Analysis Controller
- Open the vFunction Agent Startup Parameters in a text editor
### Replace the INSTANCE_NAME with the actual value
less etc/sysconfig/vfunction/agent/instances/INSTANCE_NAME/vmargs-examples/raw
- Add the vFunction Startup Parameters to the JAVA_OPTS of the Application
JVM is Started Manually - Sample
### Before Adding vFunction
java -jar app.jar
### After Adding vFunction
##### Find-and-Replace REPLACE_BASE_DIR with the location of the installation, such as "/tmp/vfunction". If the installation was done as a Sudo / Root user, remove this string
##### Find-and-Replace REPLACE_EXTRA_JVM with "--add-opens java.base/java.lang=ALL-UNNAMED" if the JVM uses Java 11, 17, 21. Otherwise, remove this string
##### Find-and-Replace REPLACE_INSTANCE with the name of the intance, such as "default-java"
java -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 REPLACE_EXTRA_JVM -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 -jar app.jar
JVM is Started via a Script - Sample
### Before Adding vFunction
JAVA_OPTS="-Xmx4g"
java $JAVA_OPTS -jar app.jar
### After Adding vFunction
##### Find-and-Replace REPLACE_BASE_DIR with the location of the installation, such as "/tmp/vfunction". If the installation was done as a Sudo / Root user, remove this string
##### Find-and-Replace REPLACE_EXTRA_JVM with "--add-opens java.base/java.lang=ALL-UNNAMED" if the JVM uses Java 11, 17, 21. Otherwise, remove this string
##### Find-and-Replace REPLACE_INSTANCE with the name of the intance, such as "default-java"
JAVA_OPTS="-Xmx4g"
VFUN_OPTS="-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 REPLACE_EXTRA_JVM -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"
JAVA_OPTS="$VFUN_OPTS $JAVA_OPTS"
java $JAVA_OPTS -jar app.jar
- Confirm that the Application comes up and functions as expected
- If any issues arise: