Saturday, February 22, 2014

Controlling ApacheMQ through JMX

See http://activemq.apache.org/jmx.html; first option described ("The ActiveMQ broker should appear in the list of local connections, if you are running JConsole on the same host as ActiveMQ.") didnt't work for me (ActiveMQ was started as a service, maybe this was  the cause...)

So:

  • go into bin/win64 and edit wrapper.conf; uncomment the following lines:
    • wrapper.java.additional.16=-Dcom.sun.management.jmxremote.port=1616
    • wrapper.java.additional.17=-Dcom.sun.management.jmxremote.authenticate=false
    • wrapper.java.additional.18=-Dcom.sun.management.jmxremote.ssl=false
  • be aware that you need to change the default format so that 16,17 and 18 replace the original .n format (be aware that the sequence might be different depending on other changes you made to the conf file)
  • restart ActiveMQ
  • go to your JDK\bin directory and start jconsole.exe
  • provide the following URL for Remote Process:
    • service:jmx:rmi:///jndi/rmi://localhost:1616/jmxrmi
  • press Connect (do not fill in any data for user/password)
  • press Insecure on the pop-up
  • etc...
If secure connection is required (I suppose by changing the wrapper options accordingly) provide the user name/passord for the relevant role as configured in conf\jmx.access and conf\jmx.password


No comments :

Post a Comment