For no obvious reason, actually...
At first I did not have these parameters, neither on broker1 nor on broker2;
however, upon starting broker1 first, I noticed this line:
JMX consoles can connect to
service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi |
org.apache.activemq.broker.jmx.ManagementContext | JMX connector
So, I assumed (I know, assumption is the mother of all ehrm... ) there would
be one "overall" process that would kind of redirect connections to the
"real" process, acting like a kind of proxy so to say.
As you can see, broker1 has the same configuration, with port 1099 whereas
port 11099 is the port in the environment file;
I'll remove both parameters in the activemq.xml
So, broker1 now has this managementContext:
<managementContext createConnector="true"
useMBeanServer="true"
createMBeanServer="true"
/>
</managementContext>
and broker2 now has this managementContext:
<managementContext>
<managementContext createConnector="true"
useMBeanServer="true"
createMBeanServer="true"
/>
</managementContext>
Broker1 reports:
JMX consoles can connect to
service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi
And broker2:
Failed to start JMX connector Cannot bind to URL
[rmi://localhost:1099/jmxrmi]: javax.naming.NameAlreadyBoundException:
jmxrmi [Root exception is java.rmi.AlreadyBoundException: jmxrmi]. Will
restart management to re-create JMX connector, trying to remedy this issue.
And, naturally it doesn't connect to the mbean server.
--
View this message in context:
http://activemq.2283324.n4.nabble.com/What-is-the-proper-way-to-configure-multiple-brokers-on-the-same-machine-in-regard-to-jmx-tp4715589p4715623.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.