VMware Cloud Community

Problem running agent to monitor JBoss 4.2 instance


I am running the agent on a machine that has JBoss 4.2 installed.

The agent starts with no errors and sends system metrics (cpu, disk, etc.) to the hyperic server but when it tries to contact the JBoss instance the following exception shows up in the agent.log file.

2007-12-11 12:12:46,955 WARN [RuntimeAutodiscoverer] Error running autodiscoverer for plugin: JBoss 4.2: null
at org.hyperic.hq.plugin.jboss.JBossDetector.discoverJBossServices(JBossDetector.java:593)
at org.hyperic.hq.plugin.jboss.JBossDetector.discoverServices(JBossDetector.java:578)
at org.hyperic.hq.product.ServerDetector.discoverResources(ServerDetector.java:201)
at org.hyperic.hq.autoinventory.agent.server.RuntimeAutodiscoverer.doRuntimeScan_internal(RuntimeAutodiscoverer.java:292)
at org.hyperic.hq.autoinventory.agent.server.RuntimeAutodiscoverer.doRuntimeScan(RuntimeAutodiscoverer.java:220)
at org.hyperic.hq.autoinventory.ScanManager.mainRunLoop(ScanManager.java:165)
at org.hyperic.hq.autoinventory.ScanManager.access$000(ScanManager.java:41)
at org.hyperic.hq.autoinventory.ScanManager$1.run(ScanManager.java:107)
Caused by: javax.naming.CommunicationException [Root exception is java.rmi.UnmarshalException: Error unmarshaling return header; nested exception is:
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:724)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:589)
at javax.naming.InitialContext.lookup(InitialContext.java:351)
at org.hyperic.hq.plugin.jboss.JBossUtil.getMBeanServer(JBossUtil.java:119)
at org.hyperic.hq.plugin.jboss.JBossDetector.discoverJBossServices(JBossDetector.java:591)
... 7 more
Caused by: java.rmi.UnmarshalException: Error unmarshaling return header; nested exception is:
at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:203)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)
at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:627)
... 11 more
Caused by: java.io.EOFException
at java.io.DataInputStream.readByte(DataInputStream.java:243)
at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:189)
... 14 more

The hyperic server, agent and JBoss instance are all running on the same machine. I'm aware that this is not ideal but I have no alternative.

There are also some oracle services running on the machine.

I've tried to replicate the problem a development machine with the same configuration (except for the oracle services) but I the agent woked just fine.

I'm attaching the agent.log file.

I would appreciate any help on this issue.

Thanks in advance,
0 Kudos
1 Reply
VMware Employee
VMware Employee

Hi Cristian,

I think the problem is due to having JBoss 4.2 on the same box as HQ's 4.0.3 JBoss, where the HQ jboss-plugin is using HQ's JBoss for the classpath. You can trying forcing it to use the 4.2. classpath in agent.properties like so:


And restart the agent. The catch is you likely won't be able to monitor HQ's JBoss.
0 Kudos