ETC Tip2009. 1. 6. 10:59

Generating a Thread Dump with 1.3.x_x JRE/JDK

  1. Use the command # ps -ef | grep jrun to find the JRun server process id:
    [root@linuxbox2 bin]# ps -ef | grep jrun
    root 9291 1 6 14:30 pts/1 00:00:05 ./jrun -start -nohup default
    root 9292 9291 0 14:30 pts/1 00:00:00 ./jrun -start -nohup default
    root 9293 9292 0 14:30 pts/1 00:00:00 ./jrun -start -nohup default
    ....................................................................................................
  2. From the list of returned processes, find the process ID with a parent id of 1 -in this case it is 9291 (the parent process ID is listed in the third column, immediately after the process ID itself)
    ....................................................................................................
  3. Using the java process id, send a kill - 3 signal as follows to cause the JVM to generate the thread dump (the kill -3 will not stop the process):
    [root@linuxbox2 bin]# kill -3 9291
    ....................................................................................................
  4. Look in the dump-out.log for the output of the thread dump
Posted by 항아리고미