JMX Consoles
Resin 3.0

Features
Installation
Configuration
Web Applications
IOC/AOP
Resources
JSP
Quercus
Servlets and Filters
Databases
Admin (JMX)
CMP
EJB
Amber
EJB 3.0
Security
XML and XSLT
XTP
JMS
Performance
Protocols
Third-party
Troubleshooting/FAQ

Servlet
JMX Consoles
Instrumenting
Tutorials
Cookbook
Servlet
Admin (JMX)
Instrumenting

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.

  1. JDK 5.0 and JMX

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.

Start Resin and allow local JMX administration
win> ./httpd.exe -Dcom.sun.management.jmxremote
unix> bin/httpd.sh -Dcom.sun.management.jmxremote

Start jconsole
win> jconsole.exe
unix> jconsole

Choose Resin's JVM from the "Local" list.

Start Resin and allow remote JMX administration
win> ./httpd.exe -Dcom.sun.management.jmxremote.port=9999
unix> bin/httpd.sh -Dcom.sun.management.jmxremote.port=9999

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.

Start Resin and remote JMX - disable password checking and SSL

win> ./httpd.exe -Dcom.sun.management.jmxremote.port=9999
                 -Dcom.sun.management.jmxremote.ssl=false
                 -Dcom.sun.management.jmxremote.authenticate=false

unix> bin/httpd.sh -Dcom.sun.management.jmxremote.port=9999 \
                   -Dcom.sun.management.jmxremote.ssl=false \
                   -Dcom.sun.management.jmxremote.authenticate=false

Start jconsole
win> jconsole.exe
unix> jconsole

Enter the host name and port number (9999) on the "Remote" tab

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

Start Resin and remote JMX - disable SSL

win> ./httpd.exe -Dcom.sun.management.jmxremote.port=9999
                 -Dcom.sun.management.jmxremote.ssl=false

unix> bin/httpd.sh -Dcom.sun.management.jmxremote.port=9999 \
                   -Dcom.sun.management.jmxremote.ssl=false

Start jconsole
win> jconsole.exe
unix> jconsole
Enter the host name and port number (9999) on the "Remote" tab Enter the username and password on the "Remote" tab


Servlet
Admin (JMX)
Instrumenting
Copyright © 1998-2006 Caucho Technology, Inc. All rights reserved.
Resin® is a registered trademark, and HardCoretm and Quercustm are trademarks of Caucho Technology, Inc.