Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1540527 - Exceptions in server and agent log after uninvetory of platform with storage node
Exceptions in server and agent log after uninvetory of platform with storage ...
Status: CLOSED ERRATA
Product: JBoss Operations Network
Classification: JBoss
Component: Inventory, Agent, Plugin -- Other (Show other bugs)
JON 3.3.10
Unspecified Unspecified
medium Severity medium
: ER01
: JON 3.3.11
Assigned To: Michael Burman
Prachi
: Regression, Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2018-01-31 05:04 EST by Filip Brychta
Modified: 2018-10-16 13:07 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2018-10-16 13:06:49 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
latest agent.log (192.78 KB, text/plain)
2018-09-19 09:44 EDT, Prachi
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2018:2930 None None None 2018-10-16 13:07 EDT

  None (edit)
Description Filip Brychta 2018-01-31 05:04:07 EST
Description of problem:
$Summary

Version-Release number of selected component (if applicable):
JON3.3.10

How reproducible:
Always

Steps to Reproduce:
1. install and start jon 3.3.10
2. uninventory whole platform contain storage node


Actual results:
in agent.log:
2018-01-31 04:58:04,044 ERROR [ResourceDiscoveryComponent.invoker.daemon-114] (org.rhq.plugins.agent.AgentDiscoveryComponent)- An error occurred while attempting to auto-discover the agent's own management interface
java.lang.NullPointerException
	at org.rhq.plugins.agent.AgentDiscoveryComponent.getResourceKey(AgentDiscoveryComponent.java:133)
	at org.rhq.plugins.agent.AgentDiscoveryComponent.discoverResources(AgentDiscoveryComponent.java:76)
	at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.rhq.core.pc.util.DiscoveryComponentProxyFactory$ComponentInvocationThread.call(DiscoveryComponentProxyFactory.java:305)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)


in server.log:
11:20:56,488 ERROR [org.rhq.enterprise.server.alert.engine.internal.AlertConditionCacheCoordinator] (EJB default - 3) Could not find agent for scheduleId = 24669

Expected results:
NPE should be fixed. Not sure if the error in server.log is expected

Additional info:
NPE in agent log is visible even when uninventoring platform without storage node.
Error in server.log was visible only once, it's not visible when doing uninventory second time.
Comment 1 Filip Brychta 2018-02-02 11:49:41 EST
The NPE is visible in JON 3.3.9 but the ERROR in server log is not -> it's a regression.
Comment 4 Michael Burman 2018-07-09 10:01:57 EDT
In the master:

commit 8c8f998a197e2aabe065772abbfa5820fb247ce1 (HEAD -> master)
Author: Michael Burman <miburman@redhat.com>
Date:   Mon Jul 9 17:01:28 2018 +0300

    [BZ 1540527] If parentResourceContext is not available, stop discovery of agent
Comment 7 Prachi 2018-09-19 09:43:24 EDT
Server log does not have any error, but in agent logs we can still see the error:

************************************
 ERROR [ResourceDiscoveryComponent.invoker.daemon-4] (org.rhq.plugins.agent.AgentDiscoveryComponent)- An error occurred while attempting to auto-discover the agent's own management interface
java.lang.NullPointerException
	at org.rhq.plugins.agent.AgentDiscoveryComponent.getResourceKey(AgentDiscoveryComponent.java:133)
	at org.rhq.plugins.agent.AgentDiscoveryComponent.discoverResources(AgentDiscoveryComponent.java:76)
	at sun.reflect.GeneratedMethodAccessor46.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.rhq.core.pc.util.DiscoveryComponentProxyFactory$ComponentInvocationThread.call(DiscoveryComponentProxyFactory.java:305)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

************************************

Attached latest agent.log
Comment 8 Prachi 2018-09-19 09:44 EDT
Created attachment 1484734 [details]
latest agent.log
Comment 9 Michael Burman 2018-09-19 11:50:59 EDT
That line number is from an old release, so either the agent wasn't updated or the build is missing something. Lines should be 136 & 79 for the first two items in the stack trace (133 is empty line in the current release/jon3.3.x)
Comment 10 Filip Brychta 2018-09-20 02:09:30 EDT
Problem with co-located agent is that new plugins are not downloaded after upgrade until it's restarted or operation Update all plugins is manually executed.

When the agent has new plugins the issue is not visible -> marking as verified
Comment 12 errata-xmlrpc 2018-10-16 13:06:49 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2018:2930

Note You need to log in before you can comment on or make changes to this bug.