Bug 766284

Summary: EAP6 managed servers are not detected properly
Product: [Other] RHQ Project Reporter: Libor Zoubek <lzoubek>
Component: Agent, PluginsAssignee: Libor Zoubek <lzoubek>
Status: CLOSED CURRENTRELEASE QA Contact: Mike Foley <mfoley>
Severity: unspecified Docs Contact:
Priority: high    
Version: 4.3CC: hrupp, theute
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-09-02 03:18:53 EDT Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On:    
Bug Blocks: 707223    

Description Libor Zoubek 2011-12-11 08:20:38 EST
Description of problem:
I have EAP6 DR8 in domain mode. in my host.xml I have

<server name="server-one" group="main-server-group">
<!-- server-one inherits the default socket-group declared in the server-group -->
<socket-binding-group ref="standard-sockets" port-offset="50"/>
<jvm name="default">
<!-- Remote JPDA debugging for a specific server <jvm-options> <option value="-Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n"/> </jvm-options> -->
<server name="server-two" group="main-server-group" auto-start="true">
<!-- server-two avoids port conflicts by incrementing the ports in the default socket-group declared in the server-group -->
<socket-binding-group ref="standard-sockets" port-offset="150"/>
<jvm name="default">
<heap size="64m" max-size="256m"/>
<server name="server-three" group="other-server-group" auto-start="false">
<!-- server-three avoids port conflicts by incrementing the ports in the default socket-group declared in the server-group -->
<socket-binding-group ref="ha-sockets" port-offset="250"/>

agent detects domain and 3 servers successfully, but they appear offline. All three servers have detected port 9990 in Connection Settings, this seems to be default/fallback.

Version-Release number of selected component (if applicable):
Version: 4.3.0-SNAPSHOT
Build Number: 0753aae

How reproducible: always

I've found repeating this excetption in agent's log:

2011-12-11 11:25:38,954 WARN  [InventoryManager.discovery-1] (rhq.core.pc.inventory.InventoryManager)- Failure during discovery for 
[JBoss AS JVM] Resources - failed after 0 ms.
java.lang.Exception: Discovery component invocation failed.
        at org.rhq.core.pc.util.DiscoveryComponentProxyFactory$ComponentInvocationThread.call(DiscoveryComponentProxyFactory.java:29
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        at java.lang.Thread.run(Thread.java:636)
Caused by: java.lang.ClassCastException: org.rhq.modules.plugins.jbossas7.StandaloneASComponent cannot be cast to org.rhq.plugins.jmx.JMXComponent
        at org.rhq.plugins.jmx.EmbeddedJMXServerDiscoveryComponent.discoverResources(EmbeddedJMXServerDiscoveryComponent.java:56)
        at sun.reflect.GeneratedMethodAccessor27.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:616)
        at org.rhq.core.pc.util.DiscoveryComponentProxyFactory$ComponentInvocationThread.call(DiscoveryComponentProxyFactory.java:292)
        ... 5 more
Comment 1 Libor Zoubek 2011-12-21 09:12:11 EST
Build Number: 74fe0df managed servers are not detected at all
Comment 2 Heiko W. Rupp 2012-01-05 05:50:05 EST
0fdee77760fd6a in master
Comment 3 Heiko W. Rupp 2012-01-05 05:53:52 EST
Actually it is aa4ec7d05bb3 -- pull --rebase modified it
Comment 4 Heiko W. Rupp 2012-01-24 10:53:56 EST
e5560988292 in master (the above commit was about the class cast exception)
Comment 5 Libor Zoubek 2012-01-26 04:28:40 EST
Version: 4.3.0-SNAPSHOT Build Number: 2967bf9 EAP6.DR12:

exception is gone, managed servers are now detected, but all marked as online, though in one of them is according to DomainController admin console off

/host=master:read-children-names(child-type=server) returns only 2 of 3 servers
Comment 6 Heiko W. Rupp 2012-01-26 06:12:43 EST
master 9586f50ca5f
Comment 7 Libor Zoubek 2012-03-16 08:12:59 EDT
verified Version: 4.4.0-SNAPSHOT Build Number: 88ae0d8
Comment 8 Heiko W. Rupp 2013-09-02 03:18:53 EDT
Bulk closing of issues that were VERIFIED, had no target release and where the status changed more than a year ago.