Quantcast
Channel: Abhisar's Blog
Viewing all articles
Browse latest Browse all 37

Core Dump and Stack Tace on Linux of a Java process

$
0
0
Steps for taking the Core Dump
Run the command
# ps -ef | grep java

get the process id of the java process you want to get the core dump.

Next run the command
# gdb --pid=
Next
gdb>gcore
This should create a file core. in the /var/tmp location

Remember its a binary file.

If I find some other better way to take the dump, I would update.
If you know other ways please let me know.

Steps fr taking the stack Trace
jstack [-l] pid (simple)

Difference between core dump and Stack Trace

Core dump prints the complete memory map of a process and stack trace prints the state of threads of a processs.

Viewing all articles
Browse latest Browse all 37

Trending Articles