WebSphere OutOfMemory Errors
There are a variety of ways to obtain a dump from the IBM software development kit and various formats for the dump produced. It important to understand the content of each of the dumps so that the correct one can be selected for analysis of a given problem. In essence there are three forms of dump:
- A system dump which is a complete dump of all the information in a process. The Dump Analyzer requires this form of dump to perform analysis.
- A heap dump which gives a more terse view of the objects in the heap but does not include thread and monitor information. This form of dump is of use to other tools for heap analysis.
- A summary dump sometimes called a javacore file. This is a human readable dump designed to summarise the state of the process in high level terms; the threads, monitors etc.
To generate a system dump automatically on an OOM you will need to set the following JVM generic argument:-Xdump:system:events=systhrow,filter=java/lang/OutOfMemoryError,request=nodumps+exclusive+prepwalk
You can have multiple -Xdump options on the command line.
-Xdump agents are always merged internally by the JVM, as long as none of the agent settings conflict with each other.
-Xdump:java+heap+system+snap:events=user -Xdump:system:events=systhrow,filter=java/lang/OutOfMemoryError,request=nodumps+exclusive+prepwalk
-X options are specified as generic JVM arguments on WebSphere Application Server 6.1 as follows:
In the Administration Console select Servers
- Select Application Servers
- Click on the name of your server
- In the Server Infrastructure section, expand Java and Process Management and select Process Definition > Java Virtual Machine
- Scroll down and locate the textbox for Generic JVM arguments.
Please also see Crash on AIX produces no core or a truncated core to prevent a truncated core from being generated on AIX.
Happy debugging :-)
Please note these events ONLY work for IBM Java5 and Java6 JVMs.