Bug 502475 - Monitoring: scout config push fails
Summary: Monitoring: scout config push fails
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: Monitoring
Version: 530
Hardware: All
OS: Linux
high
high
Target Milestone: ---
Assignee: Miroslav Suchý
QA Contact: Preethi Thomas
URL:
Whiteboard:
Depends On:
Blocks: 463877 486216
TreeView+ depends on / blocked
 
Reported: 2009-05-25 12:25 UTC by Milan Zázrivec
Modified: 2009-09-10 18:16 UTC (History)
2 users (show)

Fixed In Version: sat530
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-09-10 18:16:08 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Milan Zázrivec 2009-05-25 12:25:49 UTC
Description of problem:
New Satellite-5.3.0-RHEL5-re20090521.1 installation with enabled monitoring
and enabled monitoring scout:
* Scout config push fails
* MonitoringScout restart dumps a html text into console

These two things make monitoring completely unusable.

Version-Release number of selected component (if applicable):
Satellite-5.3.0-RHEL5-re20090521.1
spacewalk-setup-0.5.27-10
eventReceivers-2.20.11-4

How reproducible:
Always

Steps to Reproduce:
1. Install Satellite 5.3.0, enable monitoring, monitoring scout
2. Do scout config push in web ui
3. service MonitoringScout restart
  
Actual results:
Scout config push fails.
MonitoringScout service restart dumps a long html text into console.

Expected results:
Scout config push succeeds, MonitoringScout service restart succeeds.

Additional info:
* Satellite-5.3.0-RHEL5-re20090521.1:
SQL> select sc.vip, sn.ip from rhn_sat_cluster sc, rhn_sat_node sn;

VIP             IP
--------------- ---------------

* Satellite 5.2.0:
SQL> select sc.vip, sn.ip from rhn_sat_cluster sc, rhn_sat_node sn;

VIP             IP
--------------- ---------------
10.34.32.86     10.34.32.86

SQL> 

* In 5.2.0, rhn_sat_node & rhn_sat_cluster tables are populated by java
stack when enabling monitoring / monitoring scout. In 5.3.0 this part was
moved over to installer (spacewalk-setup), which does not set the
IP addresses as it should.

* Downgrading eventReceivers package to version 2.20.11-2 will cause monitoring
to work correctly again, but we'll loose fixes for bugs #499568, #499568.
So in fact fixes in MonitoringAccessHandler.pm revealed the problem with
rhn_sat_node & rhn_sat_cluster not being populated properly during new
satellite installation.

Comment 1 Miroslav Suchý 2009-05-28 13:11:10 UTC
Temporary workaround is to do:
   update rhn_sat_cluster set vip=ipofseatellit;   
   update rhn_sat_node set ip=ipofseatellit;

Comment 2 Miroslav Suchý 2009-05-28 16:57:34 UTC
I add the ip to scout in commit 0585800ce135717425e7f363df14593bc9a8f908

Comment 3 Miroslav Suchý 2009-05-29 12:01:50 UTC
I removed the scout initialization from spacewalk-setup, this way code from:
code/src/com/redhat/rhn/manager/satellite/ConfigureSatelliteCommand.java
can create scout.
It on the other hand invalidate BZ 489350, but it was introduced during work 458355, but made it unnecessary during future work on the same bug (458355).

Commit 311273317beb8f8539b50d2e281287751e3cb90f.

Comment 4 Miroslav Suchý 2009-06-05 12:56:55 UTC
Moving ON_QA
QA Build: 20090529

Comment 5 Miroslav Suchý 2009-06-05 14:19:27 UTC
err of course QA build 20090605

Comment 6 Preethi Thomas 2009-06-09 18:08:25 UTC
Miroslav,

I think its fails_qa looking at the error from  service MonitoringScout restart
but the database part seems to be fixed.

Put in back on_qa with your comment if you disgree and if the bug was to just fix the database part.

[root@rlx-3-08 ~]# service MonitoringScout restart
Stopping MonitoringScout ...  Stopping Dispatcher ...  [ OK ]
Stopping Dequeuer ...  [ OK ]
Stopping SputLite ...  [ OK ]
Stopping NPBootstrap ...  [ OK ]
[ OK ]
Starting MonitoringScout ...  Starting NPBootstrap ...  2009-06-09 14:00:48 NPBootstrap:        !! ERROR FROM SHELL COMMAND: 
2009-06-09 14:00:48 NPBootstrap:        !! STDOUT: 
2009-06-09 14:00:48 NPBootstrap:        !! STDERR: can't open /var/lib/nocpulse/CommandParameter.db: No such file or directory at /usr/lib/perl5/vendor_perl/5.8.8/NOCpulse/Probe/Config/Command.pm line 53

2009-06-09 14:00:48 NPBootstrap:        !! EXIT: 512
[ FAIL ]
2009-06-09 14:00:48 NPBootstrap: WARNING: STARTED BUT *NOT* RUNNING
2009-06-09 14:00:48 NPBootstrap: ERRORS ENCOUNTERED DURING LAST ACTION:
2009-06-09 14:00:48 NPBootstrap:        !! ERROR FROM SHELL COMMAND: 
2009-06-09 14:00:48 NPBootstrap:        !! STDOUT: 
2009-06-09 14:00:48 NPBootstrap:        !! STDERR: can't open /var/lib/nocpulse/CommandParameter.db: No such file or directory at /usr/lib/perl5/vendor_perl/5.8.8/NOCpulse/Probe/Config/Command.pm line 53

2009-06-09 14:00:48 NPBootstrap:        !! EXIT: 512
Starting SputLite ...  [ OK ]
Starting Dequeuer ...  [ OK ]
/etc/init.d/MonitoringScout: line 17:  6589 Terminated              /usr/sbin/MonitoringScout $@
[root@rlx-3-08 ~]# 
[root@rlx-3-08 ~]# 
[root@rlx-3-08 ~]# 
[root@rlx-3-08 ~]# su - oracle
-bash-3.2$ sqlplus rhnsat@rhnsat/rhnsat

SQL*Plus: Release 10.2.0.4.0 - Production on Tue Jun 9 14:03:51 2009

Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL> select sc.vip, sn.ip from rhn_sat_cluster sc, rhn_sat_node sn;

VIP             IP
--------------- ---------------
10.10.76.179    10.10.76.179

Comment 7 Miroslav Suchý 2009-06-10 05:59:15 UTC
Preethi, did you have selinux in permissive or enforcing?

Comment 8 Miroslav Suchý 2009-06-10 09:07:47 UTC
I can not reproduce it. If it was run in enforcing, then it should be fixed by my commit
249f66e71268a8f05ee376c989a51d1cdc719bce in
https://bugzilla.redhat.com/show_bug.cgi?id=498611#c4

Comment 9 Preethi Thomas 2009-06-11 21:08:58 UTC
I had it in enforcing.

Comment 10 Miroslav Suchý 2009-06-12 12:59:21 UTC
compose 20090612
moving ON_QA

Comment 11 Preethi Thomas 2009-06-15 12:22:56 UTC
verified
[root@rlx-3-24 ~]# service MonitoringScout restart
Stopping MonitoringScout ...  Stopping Dispatcher ...  [ OK ]
Stopping Dequeuer ...  [ OK ]
Stopping SputLite ...  [ OK ]
Stopping NPBootstrap ...  [ OK ]
[ OK ]
Starting MonitoringScout ...  Starting NPBootstrap ...  [ OK ]
Starting SputLite ...  [ OK ]
Starting Dequeuer ...  [ OK ]
Starting Dispatcher ...  [ OK ]
[ OK ]

Comment 12 Milan Zázrivec 2009-08-20 09:42:05 UTC
Verified in stage -> RELEASE_PENDING

Comment 13 Brandon Perkins 2009-09-10 18:16:08 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHEA-2009-1434.html


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