The gadget spec URL could not be found

SAP Java generate heap dump in .hprof format

Why heap dump required

Your SAP Java stack server node is crashing with OutOfMemoryError OR you are seeing following logs in dev_server<x> logs after server node restart/crash.

[Thr 3840] Fri Nov 06 08:46:48 2012

[Thr 3840] JLaunchIExitJava: exit hook is called (rc = 666)

[Thr 3840] **********************************************************************

  • ERROR => The Java VM terminated with a non-zero exit code.
  • Please see SAP Note 943602 , section 'J2EE Engine exit codes'
  • for additional information and trouble shooting.


[Thr 3840] JLaunchCloseProgram: good bye (exitcode = 666)

You will get these error when your heap fell short of the memory requirement . You can analyze heap consumers  from heap dump using SAP Memory Analyzer tool(MAT).A full heap dump is required for detailed analysis of memory related problems in the Java stack.

 How to get heap dump on OOM Error
You can get the heap dump by setting up following parameters.

After adding this parameter in cluster JVM settings, it will generate heap dumps in the /usr/sap/<SID>/<instance>/j2ee/cluster/server<N> folder and Output file name format is java_pid<pid>.hprof
-XX:HeapDumpPath=<directory where to save heap dumps>   
The size of the heap dump file is usually about the size of the used heap at the moment the heap dump is written.
We recommend separate mount/folder to store dumps.  In general practice, we go with /usr/sap/dumps  whose size would be at least 5-10 times our heap size . 

This parameter  is required if you want to generate heap dump on demand.(Without OOM error).

The gadget spec URL could not be found

How to set these parameters in SAP system:
1.Launch Configtool - Go to to /usr/sap/<SID>/JC*/j2ee/configtool/ and execute (On UNIX like environment , please setup DISPLAY as per X11 /Reflection application). cluster_data/instance_ID.../server_ID... and add the parameter in the "General " tab. If you have more than one server node, you need to add these parameters to every server node.

Configtool Adding Java Heap Parameters


The gadget spec URL could not be found