I have a java process which is acting dubiously. I'd like to see what's up using the various HPROF analysis tools.
How do I generate one on the fly?
I have a java process which is acting dubiously. I'd like to see what's up using the various HPROF analysis tools.
How do I generate one on the fly?
You have to start the Java process with the correct arguments, which vary a little depending on the JVM version. Then, send a
QUIT
signal to the process to generate a new file.jconsole now has the ability to create a dump to the app's current working directory.
Jconsole Screen Shot
VisualVM can help you dig into what your process is doing, including the ability to arbitrarily force a heap dump on a running process.
Yes. You can generate an hprof file (containing heap memory usage) on the fly using the jmap tool, which ships with Sun's Java VM: