JMX
From Resin 3.0
<document> <header> <product>resin</product> <title>JMX Consoles</title> <description>
JMX Consoles provide access to both the MBean's that Resin publishes for information about and control of the Resin server and Application specific MBeans.
</description> </header>
<body> <summary localtoc="true"/>
<s1 title="JDK 5.0 and JMX">
JDK 5.0 includes a JMX implementation that is used to provide local and remote administration of a Resin server.
<example title="Start Resin and allow local JMX administration"> win> ./resin.exe -Dcom.sun.management.jmxremote unix> bin/resin.sh -Dcom.sun.management.jmxremote </example>
<example title="Start jconsole"> win> jconsole.exe unix> jconsole
Choose Resin's JVM from the "Local" list. </example>
<example title="Start Resin and allow remote JMX administration"> win> ./resin.exe -Dcom.sun.management.jmxremote.port=9999 unix> bin/resin.sh -Dcom.sun.management.jmxremote.port=9999 </example>
Without some configuration effort, the previous command will not work. Password configuration and SSL configuration is required by the JDK implementation of remote JMX. Detailed instructions are included in the JDK documentation.
The following is useful for testing, but should be done with caution as the port is not protected by password or by SSL, and if not protected by a firewall is accessible by anyone who can guess the port number.
<example title="Start Resin and remote JMX - disable password checking and SSL">
win> ./resin.exe -Dcom.sun.management.jmxremote.port=9999
-Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false
unix> bin/resin.sh -Dcom.sun.management.jmxremote.port=9999 \
-Dcom.sun.management.jmxremote.ssl=false \ -Dcom.sun.management.jmxremote.authenticate=false
</example>
<example title="Start jconsole"> win> jconsole.exe unix> jconsole
Enter the host name and port number (9999) on the "Remote" tab </example>
<example title="Setting a password for remote JMX access"> $ cd $JAVA_HOME/jre/lib/management $ cp jmxremote.password.template jmxremote.password $ chmod u=rw jmxremote.password $ vi jmxremote.password
Set a password for "monitorRole" and "controlRole":
monitorRole 12monitor controlRole 55control </example>
<example title="Start Resin and remote JMX - disable SSL">
win> ./resin.exe -Dcom.sun.management.jmxremote.port=9999
-Dcom.sun.management.jmxremote.ssl=false
unix> bin/resin.sh -Dcom.sun.management.jmxremote.port=9999 \
-Dcom.sun.management.jmxremote.ssl=false
</example>
<example title="Start jconsole"> win> jconsole.exe unix> jconsole </example>
Enter the host name and port number (9999) on the "Remote" tab Enter the username and password on the "Remote" tab
</s1>
</body> </document>