[Pkg-nagios-devel] Bug#311695: Rather difficult to reproduce

Don Armstrong Don Armstrong <don@debian.org>, 311695@bugs.debian.org
Thu, 2 Jun 2005 20:33:57 -0700


The only way you can get this bug to occur is if you're configuring
the database while nagios is running, and manage to create the user so
nagios can connect, and not give it the appropriate grant statements
to actually do what it is supposed to do to the database.

Otherwise, you just get a string of messages like the following:

root@archimedes:/# less /var/log/nagios/nagios.log 
[1117766679] Nagios 1.3 starting... (PID=20707)
[1117766910] Nagios 1.3 starting... (PID=21683)
[1117766910] Error: Could not connect to MySQL database '' on host '' using username '' and password 'XXXXXX'.  Status data will not be saved!
[1117766910] Error: Could not connect to MySQL database '' on host '' using username '' and password 'XXXXXX'.  Retention data will not be processed or saved!
[1117766910] Error: Could not re-connect to database server on host '' for status data.  I'll keep trying every 60 seconds...
[1117766910] Error: Could not connect to MySQL database '' on host '' using username '' and password 'XXXXXX' for comment data!
[1117766910] Error: Could not connect to MySQL database '' on host '' using username '' and password 'XXXXXX' for downtime data!


which only happen every 60 seconds or so.

Since I've no clue why you'd have nagios running while you were
configuring it, and the package doesn't actually exhibit the behavoir
you describe when you've just installed it, I don't see this being RC.

Of course, nagios should fall back gracefully when it can't insert
data into a table because of a permisions error, and not try to insert
the same data over and over.

Finally, even if I've allowed nagios to connect to the database, all
it does is the following:

[1117768283] Nagios 1.3 starting... (PID=30460)
[1117768283] Error: Could not read program retention data from table programretention
[1117768283] Error: Could not read host retention data from table hostretention
[1117768283] Error: Could not read service retention data from table serviceretention
[1117768283] Error: Could not lock status data tables in database 'nagios'
[1117768298] Error: Could not lock status data tables in database 'nagios'
[1117768313] Error: Could not lock status data tables in database 'nagios'

(This is on a brand new chroot with mysql-server already runnign when
nagios was installed, and nagios started up as well.)

Since this appears to be unreproduceable on two people's systems,
critical is clearly the wrong severity.


Don Armstrong

-- 
Il semble que la perfection soit atteinte non quand il n'y a plus rien
a ajouter, mais quand il n'y a plus rien a retrancher.
(Perfection is apparently not achieved when nothing more can be added,
but when nothing else can be removed.)
 -- Antoine de Saint-Exupe'ry, Terres des Hommes

http://www.donarmstrong.com              http://rzlab.ucr.edu