Monday, September 3, 2018

manually generate heapdumps in Websphere


To manually generate heapdumps, set a JVM parameter. Then send the JVM process an interrupt (signal 3), a javacore and a heapdump will be generated.

In the Administrative Console:
Servers > Application Servers > serverName:
In the Server Infrastructure section open Java and Process Management, then select Process Definition:
In the Additional Properties select Java™ Virtual Machine:

Add the following string to the Generic JVM arguments field:
-Xdump:heap:events=user

Press OK, and save the configuration.

Note: The Application Server will need to be recycled for the setting to take effect.


To generate the heapdump, send the Application Server an interrupt. Use the "kill" command:
kill -3 <java process ID>

To get process id
ps -aux | grep java   (Look for server1)