SavaPage runs in the Java Virtual Machine (JVM) using the class libraries and other supporting files provided in the JRE.
The SavaPage JVM settings work fine, and generally there is no customization needed. However, if needed the JVM can be tuned by adding extra JVM arguments in the file:
/opt/savapage/server/custom/app-server.conf
Edit this file as savapage
user and enter the extra
JVM arguments as value of the CUSTOM_JVM_ARGS
key. The example
below shows the JVM arguments as explained in the next
sections.
# Note: enclose the value with quotes CUSTOM_JVM_ARGS="-XX:DefaultMaxRAMFraction=2 -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalMode"
The location of temporary files can be overwritten with the
JAVA_IO_TMPDIR
key.
# Overwrite of JVM system property 'java.io.tmpdir' # User 'savapage' must have mode 700 access to this directory. #JAVA_IO_TMPDIR=
Before doing any JVM customizing please consult SavaPage Support to discuss your requirements and which customization fits best.
The JVM allocates a quarter of host system RAM to the SavaPage Server process by default. This ensures that SavaPage does not consume too many resources and does not get in the way of other applications running on the same system.
However, if the host system is dedicated to running SavaPage, you can safely allocate more memory to SavaPage. With more allocated memory SavaPage will have a better performance, particularly with many users and large printing throughput.
Add one of the following JVM parameters to allocate relative or absolute memory:
Customizing Java Garbage Collection (GC) depends on the characteristics of the application involved. The JVM provide proper defaults for SavaPage most of the time.
However, if you consider response time more important than overall throughput
and garbage collection pauses must be kept shorter than approximately one
second, then select the concurrent collector with the
-XX:+UseConcMarkSweepGC
option. Also, if only one or two
processors are available, consider combining this collector with the
-XX:+CMSIncrementalMode
option.
Please consult the Java SE 6 HotSpot Oracle documentation for an introduction to these tuning options.
The Java system property java.io.tmpdir
determines where
the JVM writes temporary files. The default value typically points to the world
readable /tmp
directory. For security reasons
SavaPage sets java.io.tmpdir
to its own
/opt/savapage/server/tmp
directory, accessible by the
savapage
system user only. As a result, any
Java component that is part of SavaPage will write its temporary files to
that directory.
If you want to separate the location of temp files from the SavaPage application location, you can override the default in:
/opt/savapage/server/custom/app-server.conf
Edit this file as savapage
user and specify the
alternative temp directory at the JAVA_IO_TMPDIR
variable.
# Overwrite of JVM system property 'java.io.tmpdir' # User 'savapage' must have mode 700 access to this directory. #JAVA_IO_TMPDIR=
Use the JAVA_IO_TMPDIR
setting with the utmost care. Make sure the directory is
exclusively used for
SavaPage temporary files, and is accessible by the
savapage
system user only. If these
conditions are not met, SavaPage will not start and might get
corrupted.
SavaPage writes its own temp files to a subdirectory of
java.io.tmpdir
, called
savapage
. This subdirectory is created when
the application starts and removed when stopped.
You can overwrite this location in:
/opt/savapage/server/server.properties
Edit this file as savapage
user and specify an
absolute path at the app.dir.tmp
property. Beware that:
The custom location must reside on the same partition as the
locations for letterheads and safepages, as overwrite (or defaults)
values for the app.dir.safepages
and
app.dir.letterheads
properties.
Make sure the directory is exclusively
used for SavaPage temporary files, and is
accessible by the savapage
system user
only.
If these conditions are not met, SavaPage will not function, and crucial data of other applications might be permanently lost.