Hitachi

uCosminexus Application Server Maintenance and Migration Guide


5.8.2 When C Heap Is Insufficient

When C heap is insufficient, the message output, and dump output or core dump generation is performed in the following order:

  1. A message log indicating insufficient C heap is output to the error report file and standard output.

  2. If the memory is insufficient during the execution of 1., a simple message is output to the standard output.

  3. In UNIX, if the memory is still insufficient during the output of a simple message, output of the message and error log file is interrupted and a core dump is generated.

Each output format is described below.

Organization of this subsection

(1) Output contents of a message log indicating insufficient C heap

The output format of a message log indicating insufficient C heap is described below. This format is common for the error report file and standard output.

When such a message is output, take appropriate measures such as reducing C heap.

The output contents are as follows:

Table 5‒26: Output items of message log when C heap is insufficient

Output items

Description

ThreadName

The thread name extracted by the Thread#getName() method is output.

n

The size of memory securing requests is output.

message

The internal message required by maintenance personnel for investigation is output. In some cases it may not be output.

Java heap information

The usage status of Java heap is output.

Stack trace

The stack trace is output when the thread for which the memory is insufficient is the thread that is executing a Java code.

The stack trace is not output when the memory is insufficient in the thread that is executing internal process such as compilation process in JavaVM.

(2) Output contents of message showing memory insufficiency

If memory becomes insufficient while a message log indicating insufficient C heap is being output, the process cannot be continued. In this case, a simple message in the following format is output to the standard output.

java.lang.OutOfMemoryError:requested <n> bytes for <message>

The output contents are as follows:

Table 5‒27: Output contents of a simple message when the memory is insufficient

Output items

Description

n

The size of memory securing requests is output.

message

The internal message required by maintenance personnel for investigation is output.

(3) Output contents of the message indicating core dump generation

If the memory is still insufficient when a simple message is output, output of the message and error log file is interrupted and a core dump is generated. When a core dump is generated, the message in the following format is output in the standard output.

Can't create logs because of memory shortage.
Insufficient memory for malloc. JVM generates core file