Reputation: 147
We have HornetQ messaging running inside JBoss. From a remote VM we are unable to connect using JMXURL.
HornetQ settings (hornet1 configuration.xml):
<jmx-management-enabled>true</jmx-management-enabled>
JBoss settings
-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=3000 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false
From a remote JVM none of these URLs work:
Upvotes: 3
Views: 2949
Reputation: 160
I have changed the run.sh to :
export JMX_ARGS="-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=3000 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false"
java $JVM_ARGS -classpath $CLASSPATH $JMX_ARGS org.hornetq.integration.bootstrap.HornetQBootstrapServer $FILENAME
then when hornetq starts you should see this in the log :
15:15:22,312 CONFIG [sun.management.jmxremote] JMX Connector ready at: service:jmx:rmi:///jndi/rmi://localhost:3000/jmxrmi
on the client side you should be able to connect to the server with this :
val url = new JMXServiceURL("service:jmx:rmi:///jndi/rmi://localhost:3000/jmxrmi")
val connection = JMXConnectorFactory.connect(url, new java.util.HashMap())
def mbeanServer = connection.getMBeanServerConnection()
val objectName = new ObjectName("org.hornetq:module=Core,type=Server")
val serverInfo = mbeanServer.getMBeanInfo(objectName)
println(serverInfo.getDescription())
Upvotes: 0
Reputation: 13008
As for JBoss 6.0.0
jconsole service:jmx:rmi://localhost/jndi/rmi://localhost:1090/jmxconnector
works. If you replace localhost
with your host address, it worked as well.
Note that I started JBoss using
run.sh -c whatever --host=0.0.0.0
so that JBoss binds to all interfaces/addresses (instead of localhost only):
--host=host_or_ip ... Bind address for all JBoss services
Upvotes: 1