Database support

Dan Hopkins dan.hopkins at uk.easynet.net
Fri Nov 7 18:16:06 CET 2003


May be obvious, but make sure you compiled with the relevant mysql/pgsql
support for status/comment/downtime/retention (see docs/xdata-db.html)

Comment out the lines in nagios.cfg that specify the text status/comment etc
files, make sure you've edited resource.cfg as well as cgi.cfg to specify
the correct database details. 

>From the cli, su to the nagios user and make sure you can connect to the
database with the same details as resource.cfg and have sufficient
privileges to insert/delete data.

For what it's worth, we've had lots of problems with postgres - we're
running a couple of thousand hosts and service, which means rebuilding
indexes and vacuuming the status tables every few minutes to avoid them
slowing to a crawl (at time of writing we still have on going problems with
service checks stopping after 12-24 hours, and no solution)

mysql on the other hand seems to work fine.

As for reporting - beware that the database 'support' (as the docs show)
means the current status data, retention, comments etc NOT an extensive
event history, that still goes to the nagios.log flat file (unless I've
missed something - in which case some please correct me) We've got a global
event handler inserting event data into an event table to provide an
equivalent nagios.log history in the db. 

Kind Regards,
--                                                                     --
Dan Hopkins                                             Systems Developer
dan.hopkins at uk.easynet.net                                    Easynet Ltd 

-----Original Message-----
From: Tory Skyers [mailto:tskyers at foxroach.com]
Sent: 07 November 2003 15:15
To: nagios-users at lists.sourceforge.net
Subject: [Nagios-users] Database support


How Many people are actually using database support? I'm running into an
issue where nagios is not writing its information to the database and it's
not writing it to text files, and I'm wondering if the database support is
worth the trouble. The service binds up and locks the machine. I can't seem
to find any real help on the syntax in the config files to tell it to write
to the database instead of the text files. I have configured the lines in
the cgi.cfg but what do I tell nagios.cfg to read and write to the database?
It would be nice to have so I can build my own reporting engine to mine the
data from a database rather than text files. 
 
Tory Skyers
Network Administrator
Prudential Fox & Roach
610-993-1327
tskyers at foxroach.com
 


-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?   SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list