Skip to navigation

How to connect to JBoss EAP 6 using JConsole

Updated 2014-02-26T08:09:48+00:00

Issue

  • How to configure JMX monitoring with JBoss EAP 6?
  • After adding following JAVA_OPTIONS options to the configuration file
JAVA_OPTS="$JAVA_OPTS -Djboss.platform.mbeanserver"
JAVA_OPTS="$JAVA_OPTS -Djavax.management.builder.initial=org.jboss.mx.server.MBeanServerBuilderImpl"
JAVA_OPTS="$JAVA_OPTS  -Dcom.sun.management.jmxremote.port=9002"
JAVA_OPTS="$JAVA_OPTS  -Dcom.sun.management.jmxremote.authenticate=false"
JAVA_OPTS="$JAVA_OPTS  -Dcom.sun.management.jmxremote.ssl=false"

and getting the following errors:

WARNING: Failed to load the specified log manager class org.jboss.logmanager.LogManager
java.lang.IllegalStateException: The LogManager was not properly installed (you must set the "java.util.logging.manager" system property to "org.jboss.logmanager.LogManager")
    at org.jboss.logmanager.Logger.getLogger(Logger.java:61)
    at org.jboss.as.server.Main.main(Main.java:84)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:601)
    at org.jboss.modules.Module.run(Module.java:270)
    at org.jboss.modules.Main.main(Main.java:294)

java.lang.ClassNotFoundException: org.jboss.logmanager.LogManagererror while trying to connect to JBoss EAP6 using JConsole.

Commons Daemon procrun stderr initialized Could not load Logmanager "org.jboss.logmanager.LogManager"
java.lang.ClassNotFoundException: org.jboss.logmanager.LogManager
 at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
 at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
 at java.security.AccessController.doPrivileged(Native Method)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
 at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
 at java.util.logging.LogManager$1.run(LogManager.java:185)
 at java.security.AccessController.doPrivileged(Native Method)
 at java.util.logging.LogManager.<clinit>(LogManager.java:175)
 at java.util.logging.Logger.getLogger(Logger.java:327)
 at com.sun.jmx.remote.util.ClassLogger.<init>(ClassLogger.java:55)
 at sun.management.jmxremote.ConnectorBootstrap.<clinit>(ConnectorBootstrap.java:823)
 at sun.management.Agent.startAgent(Agent.java:244)
 at sun.management.Agent.startAgent(Agent.java:369)

javax.management.JMRuntimeException: Failed to load MBeanServerBuilder class org.jboss.system.server.jmx.MBeanServerBuilderImpl: java.lang.ClassNotFoundException: org.jboss.system.server.jmx.MBeanServerBuilderImpl
 at javax.management.MBeanServerFactory.checkMBeanServerBuilder(MBeanServerFactory.java:502)
 at javax.management.MBeanServerFactory.getNewMBeanServerBuilder(MBeanServerFactory.java:538)
 at javax.management.MBeanServerFactory.newMBeanServer(MBeanServerFactory.java:315)
 at javax.management.MBeanServerFactory.createMBeanServer(MBeanServerFactory.java:230)
 at javax.management.MBeanServerFactory.createMBeanServer(MBeanServerFactory.java:191)
 at java.lang.management.ManagementFactory.getPlatformMBeanServer(ManagementFactory.java:466)
 at sun.management.jmxremote.ConnectorBootstrap.startRemoteConnectorServer(ConnectorBootstrap.java:453)
 at sun.management.Agent.startAgent(Agent.java:244)
 at sun.management.Agent.startAgent(Agent.java:369)
Caused by: java.lang.ClassNotFoundException: org.jboss.system.server.jmx.MBeanServerBuilderImpl
 at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
 at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
 at java.security.AccessController.doPrivileged(Native Method)
 at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
 at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
 at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
 at javax.management.MBeanServerFactory.loadBuilderClass(MBeanServerFactory.java:445)
 at javax.management.MBeanServerFactory.checkMBeanServerBuilder(MBeanServerFactory.java:487)
 ... 8 more
Exception thrown by the agent : javax.management.JMRuntimeException: Failed to load MBeanServerBuilder class org.jboss.system.server.jmx.MBeanServerBuilderImpl: java.lang.ClassNotFoundException: org.jboss.system.server.jmx.MBeanServerBuilderImpl
  • How to integrate JConsole with JBoss EAP 6?
  • How do I enable JMX monitoring?
  • Found an issue that EAP 6.1 does not support sun jmx as mentioned here then how to monitor EAP process from remote machine ?

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 6.x

Subscriber content preview. For full access to the Red Hat Knowledgebase, please log in.

Not a subscriber? Learn more about the benefits of Red Hat Subscriptions.