Re-reading of config files with no interruption
Bjørnar Bjørgum Larsen
bjornar.bjorgum.larsen at ementor.no
Fri Oct 3 14:43:34 CEST 2003
Hello list,
1. There should be a way of letting the nagios process reread its config-files without restarting it. Ideally, this would not interrupt ongoing checks. Any plans to make this happen in 2.0?
A couple of ideas on how to make it work, based on how other programs do it. From the DNS world:
A. The traditional bind / kill -HUP approach. Hmmm. Generally one shouldn't have to send signals to a process for it to see that its own configuration has changed. Besides, it can be hard for the process to catch the signal in the right way in all possible situations.
B. The tinydns / make approach. Once you've edited your config files, do a "make" (eg. in the etc catalogue). If there's no errors in the config-files, make will change some other file. For tinydns the config is compiled to cdb, not necessarily what we want for Nagios. Anyway, Nagios monitors the changes of this file, say every minute, and when it's changed will know it's supposed to reread its configuration. A simplification of this approach would be to just require users to touch a non-config file in the etc directory whenever nagios is to reread its config.
2. Other ideas?
:) Bjørnar
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
More information about the Developers
mailing list