Run java monitoring tools inside a JRE (not JDK)

Monitoring tools are not included in JRE so if you can’t install a JDK the following files can be copied to the JRE.
Note! The JDK must match the JRE version.

All platforms

<JDK_ROOT>/lib/tools.jar –> <JRE_ROOT>/lib/tools.jar
<JDK_ROOT>/lib/jconsole.jar –> <JRE_ROOT>/lib/jconsole.jar

Ubuntu 12.04

<JDK_ROOT>/jre/lib/amd64/libattach.so –> <JRE_ROOT>/bin/libattach.so
<JDK_ROOT>/bin/jconsole –> <JRE_ROOT>/bin/jconsole
<JDK_ROOT>/bin/jmap –> <JRE_ROOT>/bin/jmap
<JDK_ROOT>/bin/jps -> <JRE_ROOT>/bin/jps

Windows

<JDK_ROOT>\bin\jconsole.exe –> <JRE_ROOT>\bin
attach.dll – <JRE_ROOT>\bin
jmap.exe – <JRE_ROOT>\bin
jps.exe - <JRE_ROOT>\bin

Info found here:
http://www.oracle.com/technetwork/java/javase/jrereadme-182762.html

Monitor Java app started as Windows Service under local system account

1. Install a service using sc.exe – that will open a command prompt under local service account by executing this on cmd window

sc create debugservice binpath= "cmd /K start" type= own type= interact

2. sc start debugservice

(on a remote desktop session, this service has to be started only in console session for the command prompt window to pop up)
will print message that [SC] StartService FAILED 1053: but will start a command prompt under local system account.

3. Launch e.g. jconsole.exe