Modify the Java memory settings
Before running the commands shown on this page, you should load the Bitnami stack environment by executing the installdir/use_APPNAME script (Linux and MacOS) or by clicking the shortcut in the Start Menu under “Start -> Bitnami APPNAME Stack -> Application console” (Windows). On OS X VMs, the installation directory is /opt/bitnami and OS X VM users can click the “Open Terminal” button to run commands. Learn more about the Bitnami stack environment and about OS X VMs.
The Java Virtual Machine (JVM) determines the default settings for your Java application:
JAVA_OPTS="-Xms256m -Xmx512m"
The Tomcat server uses CATALINA_OPTS
to set these Java settings when running:
CATALINA_OPTS="-Xms256M -Xmx768M"
You can increase these settings if necessary by following the steps below:
Linux and Mac OS X
Modify the settings file installdir/apache-tomcat/bin/setenv.sh:
$ export CATALINA_OPTS="$CATALINA_OPTS -Xms256M -Xmx768M"
NOTE: You could also modify the Java Virtual Machine (JVM) settings if you prefer.
$ export JAVA_OPTS="$JAVA_OPTS -Xms256M -Xmx768M"
Restart Tomcat after modifying the file:
$ installdir/ctlscript.sh restart tomcat
Windows
Modify the settings file installdir/apache-tomcat/bin/setenv.bat:
$ SET CATALINA_OPTS="%CATALINA_OPTS% -Xms256M -Xmx768M"
NOTE: You could also modify the Java Virtual Machine (JVM) settings if you prefer.
$ SET JAVA_OPTS="%JAVA_OPTS% -Xms256M -Xmx768M"
Reinstall the services after modifying the file, as shown below. Run the following commands from an elevated command prompt:
$ cd installdir $ serviceinstall.bat UNINSTALL $ serviceinstall.bat INSTALL