nagios reload from crontab on 5 mins ?

Ton Voon tonvoon at gmail.com
Wed Sep 1 10:01:53 CEST 2010


On 1 Sep 2010, at 07:43, b2 wrote:

> I have to do rebuild my nagios2 configuration. The idea is to get
> hosts.cfg and hostgroups.cfg dynamically from MySQL DB , the
> 'get_config.pl' script first connects to db , retrieve hosts and then
> print values to hosts.cfg. , then reload nagios. Everything is fine  
> with
> the hosts.cfg but if I put the 'get_config.pl' to crontab in 5 mins  
> the
> nagios proccess terminates maybe because nagios own step is 5 minutes
> and two reloads at same time conflicts with each other ? Any  
> suggestions
> when to reload nagios to work with the new config  , or not to reload
> the nagios proccess an rely on its own 5 mins step reload ? Am i  
> missing
> soemthing here ?

Reloading every 5 minutes is not advised. You only want to reload when  
you've made changes to the DB.

However, you've basically described Opsview (http://opsview.com): do  
configuration changes in the database, then generate Nagios  
configuration by kicking off a reload. Bonus points: Opsview will also  
generate the configurations on any distributed slave systems at the  
same time!

Ton


------------------------------------------------------------------------------
This SF.net Dev2Dev email is sponsored by:

Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd
_______________________________________________
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