This content has been marked as final. Show 3 replies
Which version of jdk you are using?
Try jstack tool which is part of jdk. If it is jvm is hung you can use jstack -F <pid>.
This prints the stack trace of all threads. On 1.5 pre version you can send ctrl-break signal to dump all threads stack trace..
If you are just interested in threads then filter out stack trace dumped by this tool using shell
Thanks very much for the response JDK verions is 1.4.
FYI.. the applicaiton is installed on Red Hat Linux OS. Sun Website says that jstack is not currently available on Windows Platform or on Linux platform. wondering if it works.
Morver i see some other tool dmstool, which gives active.threads at any point of time with the command $ dmstool -JVM. I could see messages like
activeThreads.maxValue: 88.0 threads
activeThreads.minValue: 7.0 threads
activeThreads.value: 88 threads
but not sure if this is correct.
Wondering if you helpout on this.
Also, i see that there are some tools like JProbe from Quest, Optimizeit from Borland and JProfile from EJ which would be use ful for monitering the JVM. But i am not sure if these can be used to monitor on Live environment. .. Please let me know your thought around this.
1.5 and later version of java has better monitoring tools.
I have not used jprobe and optimizeit. I think these tools use jvmdi to get threads list
and it should be ok to monitor threads but better check with them to find out if it is ok to use
it on live system.
You can also try the jdb to monitor the threads. It is not realtime. You have to run
command to get threads. jdb is an experimental/demo tool. Not supported by sun.
So use it at your risk. If you are just looking at threads then it should not do any
harm to jvm.