Most Popular
Recently Added
Recently Updated

Taking a Heap Dump on *nix

TO TAKE A HEAP DUMP

  • Run jcmd command from the command line on the server running the SymmetricDS instance. This will show the Java processes and their process IDs that are currently running.
# jcmd

3927 sun.tools.jcmd.JCmd
1421 /Users/philipmarzullo/symmetric/lib/symmetric-wrapper.jar exec /Users/philipmarzullo/symmetric/conf/sym_service.conf
1422 org.jumpmind.symmetric.SymmetricLauncher --max-idle-time=90000 --no-log-console
  • The line that contains the org.jumpmind.symmetric.SymmetricLauncher class running as the main is the one that you are interested in.

  • Run jcmd to create a heap dump.
# jcmd 1422 GC.heap_dump /tmp/heap.out

# ls -l /tmp/heap.out
-rw-------  1 philipmarzullo  wheel  81272250 Dec 20 08:49 /tmp/heap.out

# file /tmp/heap.out
/tmp/heap.out: Java HPROF dump, created Fri Dec 20 13:49:03 2019

Properties ID: 000045   Views: 168   Updated: 7 months ago
Filed under: