1

Does anyone know if JRE (not JDK) has diagnostics tools, such as jps, jstack, jhat and so on?

Or these tools only present in JDK?

Thanks.

SyBer
  • 5,407
  • 13
  • 55
  • 64

1 Answers1

5

These files are all you have in the jre (jre1.6.0_20 linux):

rwxrwxrwx 1 bob bob     10 2010-05-12 19:40 ControlPanel -> ./jcontrol
-rwxr-xr-x 1 bob bob  47308 2010-04-12 22:36 java
-rwxr-xr-x 1 bob bob  25634 2010-04-12 22:39 java_vm
-rwxr-xr-x 1 bob bob  84970 2010-04-12 22:39 javaws
-rwxr-xr-x 1 bob bob   6347 2010-04-12 22:39 jcontrol
-rwxr-xr-x 1 bob bob  47447 2010-04-12 22:36 keytool
-rwxr-xr-x 1 bob bob  47679 2010-04-12 22:36 orbd
-rwxr-xr-x 1 bob bob  47515 2010-04-12 22:36 pack200
-rwxr-xr-x 1 bob bob  47807 2010-04-12 22:36 policytool
-rwxr-xr-x 1 bob bob  47447 2010-04-12 22:36 rmid
-rwxr-xr-x 1 bob bob  47447 2010-04-12 22:36 rmiregistry
-rwxr-xr-x 1 bob bob  47475 2010-04-12 22:36 servertool
-rwxr-xr-x 1 bob bob  47679 2010-04-12 22:36 tnameserv
-rwxr-xr-x 1 bob bob 189274 2010-04-12 22:36 unpack200

So, the answer is that they are only present in the JDK.

gm3dmo
  • 345
  • 5
  • 17
  • So this means I need to install them on every server... Or maybe there is another way to get diagnostic info locally? – SyBer May 12 '10 at 20:25
  • 2
    You can get the stack trace with kill -QUIT . and you can start the jvm with JMX: ``/jre1.6.0_20/bin/java -Dcom.sun.management.jmxremote -jar jpws-0-5-0.jar`` As long as you do that and enable it to be managed from another machine then no you would not need to put the JDK on every machine. – gm3dmo May 13 '10 at 07:43
  • You can start the jvm with JMX: ``/jre1.6.0_20/bin/java -Dcom.sun.management.jmxremote -jar jpws-0-5-0.jar`` As long as you do that and enable it to be managed from another machine then no you would not need to put the JDK on every machine – gm3dmo May 13 '10 at 07:45