Skip to end of metadata
Go to start of metadata

You should increase the Java heap space if JobScheduler reports out of memory Java exceptions (java heap space). The message in the log file looks like this:

 Com_set_error("Z-JAVA-105 Java exception java.lang.OutOfMemoryError("Java heap space"),
 method=spooler_process()Z []","Remote_module_instance_server::step)

There are two ways how to increase the available Java heap space. You can achieve this for individual jobs or you can apply the increment for all jobs.

Please note:

  • If you increase the initial heap space (-Xms) for all jobs you could run into memory troubles if you are running to much Java tasks at one time.
  • In most cases it is sufficient to apply just a maximum Java heap space with -Xmx.

You should descrease the Java heap space if the JVM crashes with this dump

# There is insufficient memory for the Java Runtime Environment to continue.
# Native memory allocation (malloc) failed to allocate 32744 bytes for ChunkPool::allocate
# Possible reasons:
#   The system is out of physical RAM or swap space
#   In 32 bit mode, the process size limit was hit
# Possible solutions:
#   Reduce memory load on the system
#   Increase physical memory or swap space
#   Check if swap backing store is full
#   Use 64 bit Java on a 64 bit OS
#   Decrease Java heap size (-Xmx/-Xms)
#   Decrease number of Java threads
#   Decrease Java thread stack sizes (-Xss)
#   Set larger code cache with -XX:ReservedCodeCacheSize=
# This output file may be truncated or incomplete.
#  Out of Memory Error (allocation.cpp:273), pid=5092, tid=6740
# JRE version: Java(TM) SE Runtime Environment (8.0_45-b14) (build 1.8.0_45-b14)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.45-b02 mixed mode windows-amd64 compressed oops)
# Core dump written. Default location: C:\ProgramData\\jobscheduler\extsrvsdl01vprd_4444\hs_err_pid5092.mdmp


Increment/Decrement for only one job using Java

If you want to increase the heap space for only one job you can do this by the job configuration, see

 <job java_options = "-Xmx512m"/>

Increment/Decrement for all jobs using Java

You can increase the maximum Java heap space (set by the JobScheduler when starting the JVM) within the configuration file sos.ini, for example:

 options = -Xmx512m 

You can add more Java options. For example you can set the initial and maximum Java heap space with:

 options = -Xms128 -Xmx512m 

See also

  • Please consider the different strategies of Java heap space usage covered in the article How to manage the Java heap space
  • For possible JVM options please see the Java documention


Write a comment…