Skip to end of metadata
Go to start of metadata

The JMX subsystem registers a service with the Remoting endpoint so that remote access to JMX can be obtained over the exposed Remoting connector.

This is switched on by default in standalone mode and accessible over port 9990 but in domain mode is switched off so needs to be enabled - in domain mode the port will be the port of the Remoting connector for the WildFly 8 instance to be monitored.

To use the connector you can access it in the standard way using a service:jmx URL:

You also need to set your classpath when running the above example.  The following script covers Linux.  If your environment is much different, paste your script when you have it working.


# specify your WildFly 8 folder
export YOUR_JBOSS_HOME=~/WildFly8

java -classpath $YOUR_JBOSS_HOME/bin/client/jboss-client.jar:./ JMXExample

You can also connect using jconsole.

If using jconsole use the and jconsole.bat scripts included in the /bin directory of the WildFly 8 distribution as these set the classpath as required to connect over Remoting.

In addition to the standard JVM MBeans, the WildFly 8 MBean server contains the following MBeans:

JMX ObjectName Description
jboss.msc:type=container,name=jboss-as Exposes management operations on the JBoss Modular Service Container, which is the dependency injection framework at the heart of WildFly 8. It is useful for debugging dependency problems, for example if you are integrating your own subsystems, as it exposes operations to dump all services and their current states
jboss.naming:type=JNDIView Shows what is bound in JNDI
jboss.modules:type=ModuleLoader,name=* This collection of MBeans exposes management operations on JBoss Modules classloading layer. It is useful for debugging dependency problems arising from missing module dependencies

Audit logging

Audit logging for the JMX MBean server managed by the JMX subsystem. The resource is at /subsystem=jmx/configuration=audit-log and its attributes are similar to the ones mentioned for /core-service=management/access=audit/logger=audit-log in Audit logging.

Attribute Description
enabled true to enable logging of the JMX operations
log-boot true to log the JMX operations when booting the server, false otherwise
log-read-only If true all operations will be audit logged, if false only operations that change the model will be logged

Then which handlers are used to log the management operations are configured as handler=* children of the logger. These handlers and their formatters are defined in the global /core-service=management/access=audit section mentioned in Audit logging.

JSON Formatter

The same JSON Formatter is used as described in Audit logging. However the records for MBean Server invocations have slightly different fields from those logged for the core management layer.

It includes an optional timestamp and then the following information in the json record

Field name Description
type This will have the value jmx meaning it comes from the jmx subsystem
r/o true if the operation has read only impact on the MBean(s)
booting true if the operation was executed during the bootup process, false if it was executed once the server is up and running
version The version number of the WildFly instance
user The username of the authenticated user.
domainUUID This is not currently populated for JMX operations
access This can have one of the following values:
*NATIVE - The operation came in through the native management interface, for example the CLI
*HTTP - The operation came in through the domain HTTP interface, for example the admin console
*JMX - The operation came in through the JMX subsystem. See JMX for how to configure audit logging for JMX.
remote-address The address of the client executing this operation
method The name of the called MBeanServer method
sig The signature of the called called MBeanServer method
params The actual parameters passed in to the MBeanServer method, a simple Object.toString() is called on each parameter.
error If calling the MBeanServer method resulted in an error, this field will be populated with Throwable.getMessage()
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Feb 22, 2012

    The tag <jmx-connector> has been removed in AS 7.1. The article needs revision.
    Also needs information on usage of

    Look forward to an update :)

  2. Feb 26, 2012

    I get the following exception when I run above piece of code.

    Exception in thread "main" Unsupported protocol: remoting-jmx
        at Source)
        at Source)
        at com.pcs.obix.JMXExample.main(

    Yes I fixed the issue, It was because jboss-client-7.1.0.Final.jar was missing.

    1. Feb 24, 2012

      If your using an older AS7 distribution (e.g. 7.0.*), try the older (RMI based) instructions link for AS 7.0

  3. Mar 15, 2012

    Hi, how can I expire a session in AS7.1 Final?

    In jboss-5.1.0.GA, there was an mbean named
    and its methods expireSession,listSessionIds.

    But I couldn't find this in AS7.1 Final. Please help.

    1. Mar 15, 2012

      Ok, I got the answer. I need to add the entry

              <property name="org.apache.tomcat.util.ENABLE_MODELER" value="true"/>

      in standalone-full-ha.xml. Which will solve the issue.

  4. May 15, 2012

    I was getting the error: Exception in thread "main" Unsupported protocol: remoting-jmx

    This was because of the classpath not being set.

    I found the "adding the classpath" section confusing.

    I was just trying to get remote JMX working where my client was my local IDE and the remote ejb part was on my companies non local server.

    I just added jboss-client.jar as a dependency of my test project in my IDE and I no longer got the MalformedURLException error. It then complained about authentication failure.

    I added authentication in this manner:


            String username = "DragonballZ";
            String password = "Goku55";
            HashMap env = new HashMap();
            String[] creds = new String[2];
            creds[0] = username;
            creds[1] = password;
            env.put(JMXConnector.CREDENTIALS, creds);

            JMXConnector jmxConnector = JMXConnectorFactory.connect(serviceURL, env);


    Hope this helps someone

  5. Feb 24, 2014

    i am using wildfly-8.0.0.Final configuration and also using jvisualvm tool for the JMX-connection to my remote hosts,
    below is my domain.xml configuration part

      <subsystem xmlns="urn:jboss:domain:jmx:1.3">
      <remoting-connector use-management-endpoint="false"/>

    using service:jmx:http-remoting-jmx://localhost:9990 :- to connect HostController
                service:jmx:http-remoting-jmx://localhost:8081 :  to connect Application instance
    here i can access the Hoscontroller MBean but not for Applicaiton Instance MBean

    any thoughts/suggestions to add,

    thanks in advance

  6. Feb 25, 2014

    i am facing the same issue configuring JMX in wildfly 8.0.0.Final...can someone please give us the steps to configure JMX through jconsole...?

    changes done on the domain.xml are the same as stated above 

    <subsystem xmlns="urn:jboss:domain:jmx:1.3">
                    <remoting-connector use-management-endpoint="false"/>
    <subsystem xmlns="urn:jboss:domain:jmx:1.3">
                    <remoting-connector use-management-endpoint="false"/>
    as per the jboss-as-jmx_1_3.xsd  its like
     <xs:attribute name="use-management-endpoint" type="xs:boolean" default="true" use="optional" >
                        If true then this connector will use the management endpoint, otherwise it will use the
                        remoting subsystem endpoint.
    now if we are making it false then it should be using the remoting endpoint remoting subsystem by default uses ApplicatoinRealm
    i have created application-user and password for the same but when i am trying to connect to remote server-instances its not connecting it....
    below is what i am able to connect to 
    service:jmx:http-remoting-jmx://remote_hostA:9990 --

    Unknown macro: {host A is where my domain_controller is running}

    how can i access the server-instances running on domain_controller 

    Unknown macro: {there are three server_instanaces running on HostA with a port offset of 100 each}

    i am trying to connect with the below url as 

    please let me know if i am doing something wrong here ....


    1. Feb 27, 2014

      can someone please help


  7. Mar 27, 2014

    I'm getting a RuntimeException: "Operation failed with status WAITING" while I'm trying to connect via JMX connector.

    This is the url I use: "service:jmx:http-remoting-jmx://localhost:9990".

    The strange thing is that I am able to connect with the jconsole to that server with the exact same url.

    I also tried with different ports (80 and 9999) yet with no luck.

    What am I missing?



  8. Jun 12, 2015


    I have used the code specified in the beginning of the link to connect to Wildfly server and retrieve an Mbean.I have not modified

    anything in the code given in the link.Tried running the example but getting error as follows :

    Exception in thread "main" Unsupported protocol: http-remoting-jmx
        at JMXExample.main(

    Can anyone please help me with this?

    1. Aug 29, 2015

      you need to add the jboss-client.jar in your classpath... (it is in JBOSS_HOME/bin/client)