Red Hat Training

A Red Hat training course is available for Red Hat JBoss Operations Network

9. JBoss Resources

Q: Why does only one JBoss AS server show green availability and all the rest show red, even though I made sure all of my JNP credentials are configured properly in my resources' connection properties?
Q: When I import a server like JBoss EAP 5 or Tomcat, I see its child JVM resource in inventory, but it is red (DOWN). Why?
Q: When trying to monitor a JBoss EAP instance, I get the error "Connection failure Failed to authenticate principal=null, securityDomain=jmx-console."
Q: When monitoring a JBoss AS instance, I'm not seeing any JVM resources beneath it.
Q: Can I monitor JBoss AS 5.1?
Q: My agent can detect my JBoss server and gets its connection properties, but the JNP connection fails. Why?
Q:
Why does only one JBoss AS server show green availability and all the rest show red, even though I made sure all of my JNP credentials are configured properly in my resources' connection properties?
A:
There is a problem in the way the JBoss AS JNP client works. If you are managing multiple JBoss AS servers on a single box, all of your security credentials for those servers must be the same (i.e. the JNP username and password must be the same).
Q:
When I import a server like JBoss EAP 5 or Tomcat, I see its child JVM resource in inventory, but it is red (DOWN). Why?
A:
If a server is started with JMX remoting enabled and secured, the agent cannot connect to the JMX server because it cannot detect the proper credentials.
For example, if the JMX server has these system properties:
-Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=5222
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=true
-Dcom.sun.management.jmxremote.password.file=/jmxremote.password
-Dcom.sun.management.jmxremote.access.file=/jmxremote.access
The agent's JMX plug-in examines the command line for the JMX server's process, sees that the JMX server is remoted and secured, and tries to set up its secure, remote JMX connector. Because the agent does not have the appropriate credentials, it cannot connect to the remote JMX MBean server and assumes it is in a DOWN state.
Edit the resource's Connections Settings, under the resource's Inventory tab, to enter the valid username and password set in the JMX remote access files. This enables JBoss ON to go through the remote JMX endpoint.
Alternatively, JBoss ON can connect to the parent resource, and then use that to connect to the JMX server. In that case, in the Connection Settings subtab, unset all of the connection properties except for the Type property, which should be set to Parent. The parent of the JVM, the JBoss EAP resource, can provide the information to connect to the JVM.
Q:
When trying to monitor a JBoss EAP instance, I get the error "Connection failure Failed to authenticate principal=null, securityDomain=jmx-console."
A:
As explained in the JBoss EAP documentation and the JBoss EAP 4.3 documentation, the jmx-console is secured by default. Define the username and password as instructed in the EAP documentation. Then add this username and password under the Inventory > Configuration Properties page of the JBoss EAP instance.

Note

Starting a JBoss EAP instance without specifying a configuration parameter (-c) starts the instance in production configuration.
Q:
When monitoring a JBoss AS instance, I'm not seeing any JVM resources beneath it.
A:
For JBoss ON to discover JVM resources for a JBoss AS resource, the corresponding JBoss AS instance needs to be running Java 5 or later. It also needs to have been started with the jboss.platform.mbeanserver system property set. For example, in Red Hat Enterprise Linux, the ${JBOSS_HOME}\bin\run.conf file should have this setting:
JAVA_OPTS="$JAVA_OPTS -Djboss.platform.mbeanserver"
Q:
Can I monitor JBoss AS 5.1?
A:
No. There are problems in the JBoss AS 5.1 profile service which prevent the agent from discovering it.
You can monitor JBoss EAP 5.0 and later versions and JBoss AS 6.0.
Q:
My agent can detect my JBoss server and gets its connection properties, but the JNP connection fails. Why?
A:
This primarily happens on Windows if the agent is installed in a directory with spaces in the pathname, such as C:\Program Files.
If the agent can detect the JBoss server and can find all of its connection properties, then check the logs for failures to connect to the profile service:
2012-01-12 15:03:38,982 DEBUG [ResourceContainer.invoker.daemon-1] (org.rhq.plugins.jbossas5.ApplicationServerComponent)- Failed to connect to Profile Service.
java.lang.RuntimeException: Failed to lookup JNDI name 'ProfileService' from InitialContext.
	at org.rhq.plugins.jbossas5.connection.AbstractProfileServiceConnectionProvider.lookup(AbstractProfileServiceConnectionProvider.java:84)

[snip]
Move the agent to a directory without spaces in the pathname and then re-discover the JBoss resources.