Created
January 27, 2018 08:51
-
-
Save ouyi/26bc2947fa09f27460cd096dbbf29744 to your computer and use it in GitHub Desktop.
Thread dump in Java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
top # list processes, shift+p to sort processes by CPU usage | |
top -H -p <pid> # list threads, shift+p to sort threads by CPU usages | |
printf "%x\n" <tid> # convert tid to hexadecimal, called nid | |
jstack -l <pid> | grep -i <nid> -A 15 # get stack trace of the thread |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment