Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
I created a group allhosts in hostgroups.cfg located in /usr/local/nagios/etc/objects.
When I run /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg prior this change... I receive this message
Warning: Duplicate definition found for hostgroup 'linux-servers' (config file '/usr/local/nagios/etc/objects/localhost.cfg', starting on line 46)
Error: Could not add object property in file '/usr/local/nagios/etc/objects/localhost.cfg' on line 47.
Error processing object config files!
Where and I how do I correct this problem?...It is preventing me from moving on.
I bet that the "linux-servers" hostgroup is not only defined in the localhost.cfg file, but also in the hostgroups.cfg file. Remove one of the declarations (probably from the localhost.cfg file) and try to verify once again.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Do you have the hostgroup 'linux-servers' defined multiple times in that configuration file? I'd start by taking the line it told you the issue was revolving around and figure out where and what you need to remove, after each change "such as removing a hostgroup definition" verify your configurations as you did above and eventually you will run out of errors to fix!