Jump to content
Changes to the Jaspersoft community edition download ×
  • This documentation is an older version of JasperReports Server Community Project Source Build Guide. View the latest documentation.

    Setting Java JVM Options

    To run properly, JasperReports Server needs more Java memory than the default settings. But for development work, the settings can be simpler than those recommended for production. For full information on recommended JAVA_OPTS settings, see the JasperReports Server Community Project Installation Guide.

    Tomcat and JBoss JVM Options

    Here are some typical settings for JVM options that affect JasperReports Server. For space reasons, some of the options are displayed on multiple lines; make sure you set all options.

    JVM Options on Windows

    Options for Java 1.7

    set JAVA_OPTS=%JAVA_OPTS% -Xms1024m -Xmx2048m -XX:PermSize=32m -XX:MaxPermSize=512m[/code]
    set JAVA_OPTS=%JAVA_OPTS% -Xss2m -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled[/code]                    

    JasperReports Server doesn’t provide a virtual X frame buffer on Linux. If your Linux applications are graphical, set the ‑Djava.awt.headless=true to prevent Java from trying to connect to an X-Server for image processing.

    JVM Options on Linux and Mac OSX

    Options for Java 1.7

    export JAVA_OPTS="$JAVA_OPTS -Xms1024m -Xmx2048m -XX:PermSize=32m -XX:MaxPermSize=512m"[/code]
    export JAVA_OPTS="$JAVA_OPTS -Xss2m"[/code]
    export JAVA_OPTS="$JAVA_OPTS -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled"[/code]                    

    You can set JVM options in a number of ways. For example, you can add your JAVA_OPTS settings to these files:

    File

    Add JVM Options Below the Lines Shown Here:

    <tomcat>/bin/setclasspath.bat

    set JAVA_ENDORSED_DIRS=%BASEDIR%commonendorsed[/code]                    

    <tomcat>/bin/setclasspath.sh

    JAVA_ENDORSED_DIRS="$BASEDIR"/common/endorsed[/code]                    

    <tomcat>/bin/setenv.bat or

    <tomcat>/bin/setenv.sh

    JAVA_OPTS setting can go anywhere in this file.

    <jboss>/bin/run.bat

    <jboss>/bin/run.sh

    set JAVA_OPTS=%JAVA_OPTS% -Dprogram.name=%PROGNAME% [/code]                        

    or

    export JAVA_OPTS="$JAVA_OPTS -Dprogram.name=$PROGNAME"[/code]                    

    note-icon-ns_28x28.png.8c78d0b3d48bfffbba44df2f759eb911.png

    For information on recommended JAVA_OPTS settings for all certified application servers, please refer to the JasperReports Server Community Project Installation Guide.


    User Feedback

    Recommended Comments

    There are no comments to display.



    Guest
    This is now closed for further comments

×
×
  • Create New...