nagios does not read .cfg files

Jim Mozley jim.mozley at exponential-e.com
Mon Mar 22 12:29:27 CET 2004


Peter McAlpine wrote:


>>># OBJECT CONFIGURATION FILE(S)
>>># This is the configuration file in which you define hosts, host
>>># groups, contacts, contact groups, services, etc.  I guess it would
>>># be better called an object definition file, but for historical
>>># reasons it isn't.  You can split object definitions into several
>>># different config files by using multiple cfg_file statements here.
>>># Nagios will read and process all the config files you define.
>>># This can be very useful if you want to keep command definitions 
>>># separate from host and contact definitions...
>>>
>>># Plugin commands (service and host check commands)
>>># Arguments are likely to change between different releases of the
>>># plugins, so you should use the same config file provided with the
>>># plugin release rather than the one provided with Nagios.
>>>cfg_file=/etc/nagios/checkcommands.cfg
>>>
>>># Misc commands (notification and event handler commands, etc)
>>>cfg_file=/etc/nagios/misccommands.cfg
>>>
>>># You can split other types of object definitions across several
>>># config files if you wish (as done here), or keep them all in a
>>># single config file.
>>>
>>>cfg_file=/etc/nagios/services.cfg
>>>cfg_file=/etc/nagios/contactgroups.cfg
>>>cfg_file=/etc/nagios/contacts.cfg
>>>cfg_file=/etc/nagios/hostgroups.cfg
>>>cfg_file=/etc/nagios/hosts.cfg
>>>cfg_file=/etc/nagios/timeperiods.cfg

I assume the config files above exist and are populated with reasonable 
data?

Your nagios -v output seemed to indicate 0 hosts, contact groups, etc.

You could change the cfg_file definitions in nagios.cfg or use the 
cfg_dir command to point at the directory with your config files in them 
e.g.

  cfg_dir=/usr/local/nagios/etc

Jim Mozley


-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
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