We ran into many problems getting JMX to work properly in our test environment. We are running two instances on each server in our test environment. We found the following changes got it to work and kept them using independent mbean servers.

In the bin/env file add the following (We have it on port 11009)

ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote.port=11009 -Dcom.sun.management.jmxremote.rmi.port=11009 " ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote.ssl=false" ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.authenticate=false -Djava.rmi.server.hostname=<hostname>"

In the activemq.xml file, add useJmx="true" to the <broker> tag and add/update the following element

        <managementContext>
<managementContext useMBeanServer="true" createConnector="false"/>
        </managementContext>

We do get the warning about secure/insecure however you click ok and it connects.

Also check to make sure the port is open in your firewall, the following will open the port in iptables.

-A INPUT -p tcp -m tcp --dport 11009 -j ACCEPT

From jconsole you should be able to connect now using <hostname>:<port> in the remote connection box.

Good luck!
Steve.

On 9/22/16 7:53 PM, mathewvino wrote:
activemq : apache-activemq-5.14.0
jconsole using jdk1.7

I have started the activemq which comes with the jetty server. Minor  change
to make the jmx enable is  just change <managementContext
createConnector="true"/> default is false(activemq.xml) --- I am using the
latest version 5.14.0

when i start  i am seeing the message
JMX consoles can connect to
service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi

So I start Jconsole  use remote process and use
service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi

with no password : it says secure/insecure  connection failed: not sure
where the problem is

Any help is really appreciated

<http://activemq.2283324.n4.nabble.com/file/n4716819/activemq.png>







--
View this message in context: 
http://activemq.2283324.n4.nabble.com/jconsole-using-activemq-tp4716819.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Reply via email to