HP UPC HP-UX Software - HP-UX Java, -XX:+HeapDumpOnOutOfMemoryError Not Working
Oracle suggests to add the -XX:+HeapDumpOnOutOfMemoryError Java option for their Business Suite application. This can be done by adding the option in the jserv.properties file.
The Java version used is 220.127.116.11, and according to the documentation, this option should work. But when trying to start the application, the following error appears:
Unrecognized VM option '+HeapDumpOnOutOfMemoryError' Could not create the Java virtual machine.
There is nothing wrong with Java 18.104.22.168 and the previously mentioned option.
You look at the Java version under /opt/java1.5 ,which is really 22.214.171.124, and if you run a test with the option against it, it works fine as shown below:
$/opt/java1.5/bin/java -XX:+HeapDumpOnOutOfMemoryError -version java version "126.96.36.199" .......
The issue is that Oracle Business Suite bundles Java under the hood that is not necessarily the latest version, in this case the version is 1.5.0.02, and this option is not introduced until 1.5.0.04.
The following is based on the Java 1.5.0.04 Release Notes:
-XX:+HeapDumpOnOutOfMemoryError The HeapDumpOnOutOfMemory command line option causes the JVM to dump a snapshot of the Java heap when an Out Of Memory error condition has been reached. The HeapDumpOnOutOfMemoryError functionality is available with SDK 188.8.131.52 and JDK 1.5.0.04.
As a general advise, when an application: Oracle, BEA WebLogic, IBM WebSphere, or any other application that bundles Java under the hood, gives a Java error, do not assume that the error comes from Java's default location under /opt, you need to look at the Java location that the application is using.
As a hint, use:
$ps -efx|grep java
This provides the exact directory of the Java executable.
Prefer to troubleshoot on your own?
Country: United States