RSS Feed for This PostCurrent Article

Useful Tools in JDK 6 that Developer Should Know

Some of these tools are actually available starting JDK 5.

jmap (memory map) prints shared object memory maps or heap memory details of a given process or core file or a remote debug server. If the given process is running on a 64-bit VM, you may need to specify the -J-d64 option.

jhat (Java heap analysis tool) command parses a java heap dump file and launches a webserver. jhat enables you to browse heap dumps using your favorite webbrowser. jhat supports pre-designed queries (such as ‘show all instances of a known class “Foo”‘) as well as OQL (Object Query Language) – a SQL-like query language to query heap dumps.

jconsole (Java monitoring and management console) command launches a graphical console tool that enables you to monitor and manage Java applications and virtual machines on a local or remote machine.

jps (JVM process status tool) tool lists the instrumented HotSpot Java Virtual Machines (JVMs) on the target system. The tool is limited to reporting information on JVMs for which it has the access permissions.

jstack (stack trace) prints Java stack traces of Java threads for a given Java process or core file or a remote debug server. For each Java frame, the full class name, method name, ‘bci’ (byte code index) and line number, if available, are printed.

jinfo (configuration info) prints Java configuration information for a given Java process or core file or a remote debug server. Configuration information includes Java System properties and Java virtual machine command line flags. If the given process is running on a 64-bit VM, you may need to specify the -J-d64 option.

jrunscript (command line script shell) is a command line script shell. jrunscript supports both an interactive (read-eval-print) mode and a batch (-f option) mode of script execution.

jstat (JVM statistics monitoring tool) tool displays performance statistics for an instrumented HotSpot Java virtual machine (JVM). The target JVM is identified by its virtual machine identifier.

jvisualvm – The Java VisualVM tools distributed with the JDK since JDK 6 update 7 can also be used to analyze heap dumps, thread dumps, and core files. See in particular Working with Core Dumps in the Java VisualVM guide.

 

Reference

HP-UX Java Tools and Options Tables

JDK 6 Documentation

-XX:+HeapDump and _JAVA_HEAPDUMP Environment Variable


Trackback URL


1 Trackback(s)

  1. From Troubleshooting Java on Solaris | Programming Resources | Jul 8, 2008

Sorry, comments for this entry are closed at this time.