java_opts + java_opts environment variable+ Linux java_opts+ how to set java_opts

JVM Options on Windows (64 bit)

set JAVA_OPTS=%JAVA_OPTS% -Xms1024m -Xmx2048m -XX:PermSize=32m

set JAVA_OPTS=%JAVA_OPTS% -XX:MaxPermSize=512m -Xss2m -XX:+UseConcMarkSweepGC

set JAVA_OPTS=%JAVA_OPTS% -XX:+CMSClassUnloadingEnabled

JVM Options on Linux and Mac OSX (64 bit)

export  JAVA_OPTS=-Xms1024m -Xmx8192m -XX:PermSize=32m -XX:MaxPermSize=8192m

or
export JAVA_OPTS=”$JAVA_OPTS -Xms1024m -Xmx8192m -XX:PermSize=32m -XX:MaxPermSize=8192m”

export JAVA_OPTS=”$JAVA_OPTS -Xms1024m -Xmx2048m -XX:PermSize=32m”

export JAVA_OPTS=”$JAVA_OPTS -XX:MaxPermSize=512m -Xss2m”

export JAVA_OPTS=”$JAVA_OPTS -XX:+UseConcMarkSweepGC”

export JAVA_OPTS=”$JAVA_OPTS -XX:+CMSClassUnloadingEnabled”

File Add JVM Options After This Line on Windows
<tomcat>/bin/setclasspath.bat set JAVA_ENDORSED_DIRS=%BASEDIR%\common\endorsed
<tomcat>/bin/setenv.bat JAVA_OPTS setting can go anywhere in this file.
<jboss>/bin/run.bat (JBoss 5.1) set JAVA_OPTS=%JAVA_OPTS% -Dprogram.name=%PROGNAME%
<jboss>/bin/standalone.bat (JBoss 7) rem Setup JBoss specific properties
File Add JVM Options After This Line on Linux
<tomcat>/bin/setclasspath.sh JAVA_ENDORSED_DIRS=”$BASEDIR”/common/endorsed
<tomcat>/bin/setenv.sh JAVA_OPTS setting can go anywhere in this file.
<jboss>/bin/run.sh (JBoss 5.1) export JAVA_OPTS=”$JAVA_OPTS -Dprogram.name=$PROGNAME”
<jboss>/bin/standalone.sh (JBoss 7) Add JAVA_OPTS setting before #Display our environment

Changing JVM Options for Existing Tomcat as a Windows Service

If you installed JasperReports Server to use an existing Tomcat (not the bundled component) that is running as a Windows service, you can set Java options on the Java Tab of the Tomcat Properties dialog:

1. Launch the Tomcat configuration application from the Windows Start menu:

Start > Programs > Apache Tomcat > Configure Tomcat (Run as administrator)

2. In the Apache Tomcat Properties dialog, click the Java tab.
3. In the Java Options field, add your JAVA_OPTS values according to the tables above.

Enter only the options preceded by -X or -D, not set JAVA_OPTS=%JAVA_OPTS%.

Enter only one Java option setting per line.

-Xms1024m
-Xmx2048m
-XX:PermSize=32m
-XX:MaxPermSize=512m
-Xss2m

Advertisements