IBM Support

JVM fails to create a thread with OutOfMemoryError Exception and errno2 (0xc112001e)

Troubleshooting


Problem

Multi-threaded Java application fails with unexpected java.lang.OutOfMemoryError: Failed to create a thread

Symptom

java.lang.OutOfMemoryError: Failed to create a thread: retVal -1073741830, errno 132 (0x84), errno2 -1055784930  (0xc112001e)

Cause

The JVM has been unable to create the underlying pthread because no more thread stack storage is available. If running in an AMODE64 environment every thread requires a minimum of 3MB of above the bar virtual storage for each thread's stack storage. For more details see APAR PH07475 and stack storage overview in the  Language Environment® Programming Guide. If large numbers of threads have been created or a large Java maximum heap size has been configured then overall storage usage for the address space can become limited.

Environment

IBM 64-bit SDK for z/OS, Java Technology Edition, Version 8

Resolving The Problem

If using a 64-bit JVM increase the MEMLIMIT to make more 64-bit storage available or alternatively reduce the number of threads or usage of other 64-bit storage areas such as the Java heap (-Xmx) . 
If using a 31-bit JVM increase the REGION size, reduce the number of threads, or reduce usage of other 31-bit storage areas such as the Java heap (-Xmx) or z/OS shared library region (SHRLIBRGNSIZE ).

Document Location

Worldwide

Operating System

z/OS:All operating systems listed

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSNVBF","label":"Runtimes for Java Technology"},"Component":"","Platform":[{"code":"PF035","label":"z\/OS"}],"Version":"All versions","Edition":"","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
19 March 2019

UID

ibm10876016