Troubleshooting
Problem
Could not reserve enough space for object heap
Symptom
This is noticed when you try to start a JVM. This could occur due to two possible reasons
1. java -Xmx parameter is incorrectly.
The parameter -Xmx denotes the maximum value that the heap can grow. A range of addresses equal in size to the -Xmx value is reserved at startup so the JVM can grow to the maximum heap size. The value set in this parameter is limited by the OS used. For windows, the maximum heap that can be used per process is 1.2 GB to 1.5 GB.
2. The amount of memory available to java
It could be possible that several other applications are consuming memory due to which this JVM is not able to reserve the specified amount of memory.
Error Message
Error occurred during initialization of
VM
Could not reserve enough space for object
heap
Resolving The Problem
Solution
1. If the issue occurs due to incorrect -Xmx value, make sure that the limitation mentioned above is considered and then the value is set.
2. If this application is not able to reserve sufficient memory, make sure that there are no other processes which is consuming a huge chunk of memory. If there are, probably bringing them down would help resolve the issue.
Historical Number
TRB2873
Was this topic helpful?
Document Information
Modified date:
11 February 2020
UID
swg21560996