Java 6 provides some useful console tools for analyze the state of your running Java application.
- jstack - Analyse your current stack traces of running threads (remote and local). Very useful for analyse infinite loops, threads, long time methods, ....
- jps - List your java process. Includes Main class information and so on. Very nice to list fast your running Java virtual machines.
- jstat - List performance data of your running Java VM
- jmap - List memory statistics for running Java processes.
- and a lot more of command tool. Look at http://java.sun.com/javase/6/docs/technotes/tools/index.html