Adding multiple swtiches using directories

Here is what i have, I want to monitor multiple switches so i decided to use the folder commands within nagios
*# You can also tell Nagios to process all config files (with a .cfg

extension) in a particular directory by using the cfg_dir

directive as shown below:

#cfg_dir=/usr/local/nagios/etc/servers
#cfg_dir=/usr/local/nagios/etc/printers
cfg_dir=/usr/local/nagios/etc/switches
#cfg_dir=/usr/local/nagios/etc/windows
#cfg_dir=/usr/local/nagios/etc/routers*

Now i have switches enabled and i have 1 cfg file within the directory (switches.cfg) and it works great but when i add another cfg file (switches2.cfg) nagios tanks out on me. Once i delete or move the second file everything is ok again and nagios starts up without issue. I thought the whole concept of this was so you can have multiple cfg files in one directory? or am i doing something wrong?

Thank in advance!

Start nagios with the -v option to see why its erroring out. I have folders with multiple configs.

You can call me stupid if you like. lol

I am new to lunux and i must of over looked the meaning of -v. Once i tried it and fixed a “SINGLE” issue it started working great

I thank you very much. you my friend are a life saver