By default a broker is set up to allow for JMX management. It uses the JVM's MBean
server and creates its own JMX connector at
service:jmx:rmi:///jndi/rmi://.
If the default configuration does not meet the needs of the deployment environment, the broker
provides configuration properties for customizing most aspects of its JMX behavior. For
instance, you can completely disable JMX for a broker. You can also force the broker to
create its own MBean server.hostname:1099/jmxrmi
By default JMX is enabled for a Fuse MQ Enterprise broker. To disable JMX entirely you simply
set the broker element's useJmx
attribute to false. This will stop the broker from exposing itself
via JMX.
![]() | Important |
|---|---|
Disabling JMX will also disable the commands in the activemq shell. |
In a production environment it is advisable to secure the access to your brokers'
management interfaces. To set up authentication To override the default role for JMX access
add a jmxRole property to the
etc/org.apache.karaf.management.cfg file.
If the default JMX behavior is not appropriate for your deployment environment, you can
customize how the broker exposes its MBeans. To customize a broker's JMX configuration, you
add a managementContext child element to the broker's
broker element. The managementContext
element uses a managementContext child to configure the broker.
The attributes of the inner managementContext element specify the
broker's JMX configuration.
Table 7 describes the configuration properties for controlling a broker's JMX behavior.
Table 7. Broker JMX Configuration Properties
| Property | Default Value | Description |
|---|---|---|
useMBeanServer
| true | Specifies whether the broker will use the MBean server created by the JVM. When
set to false, the broker will create an MBean server. |
jmxDomainName
| org.apache.activemq | Specifies the JMX domain used by the broker's MBeans. |
createMBeanServer
| true | Specifies whether the broker creates an MBean server if none is found. |
createConnector
| true[a] | Specifies whether the broker creates a JMX connector for the MBean server. If
this is set to false the broker will only be accessible
using the JMX connector created by the JVM. |
connectorPort
| 1099 | Specifies the port number used by the JMX connector created by the broker. |
connectorHost
| localhost | Specifies the host used by the JMX connector and the RMI server. |
rmiServerPort
| 0 | Specifies the RMI server port. This setting is useful if port usage needs to be restricted behind a firewall. |
connectorPath
| /jmxrmi | Specifies the path under which the JMX connector will be registered. |
[a] The
default configuration template for the broker sets this property to
| ||
Example 48 shows configuration for a broker that will only use the JVM's MBean server and will not create its own JMX connector.
Example 48. Configuring a Broker's JMX Connection
<broker ... > ... <managementContext> <managementContext createMBeanServer="false" createConnector="false" /> </managementContext> ... </broker>






![[Important]](imagesdb/important.gif)


