Error: Contactgroup 'linux-servers' is not defined anywhere

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.
Locked
kellyangell
Posts: 18
Joined: Mon Aug 08, 2016 3:20 am

Error: Contactgroup 'linux-servers' is not defined anywhere

Post by kellyangell »

Hello

My nagios server was working perfectly , not sure what happened now when i try to reload i get the following error

Read main config file okay...
Error: Contactgroup 'linux-servers' is not defined anywhere
Error: Could not add contactgroup 'linux-servers' to host (config file '/usr/local/nagios/etc/servers/iceINT.cfg', starting on line 1)
Error processing object config files!

I can't find the problem i have checked the conf so many times its driving me mad , please help
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: Error: Contactgroup 'linux-servers' is not defined anywh

Post by dwhitfield »

What version of Core are you running, and what is your operating system? This will help us determine commands and file locations to help fix your issue.
bwallace
Posts: 1145
Joined: Tue Nov 17, 2015 1:57 pm

Re: Error: Contactgroup 'linux-servers' is not defined anywh

Post by bwallace »

In addition to the above suggestion, did you run through the steps outlined this KB doc?
https://support.nagios.com/kb/article.php?id=128

One thing to quickly check, see if there are multiple Nagios processes running, as this will cause an array of problems.

run this cmd on your nagios server:
ps - aef | grep nagios.cfg

* Look for multiple parent (PPID) processes. The Nagios process forks itself to run checks therefore subprocesses are normal. The nagios user should probably be the only owner of the nagios process. If in any doubt post the output here.

If there are multiple Nagios processes running, run these commands to resolve:

Code: Select all

service nagios stop
killall -9 nagios
service nagios start
Also, post the /usr/local/nagios/etc/servers/iceINT.cfg file (conceal IP add's, etc)for us to review - thanks.
Be sure to check out the Knowledgebase for helpful articles and solutions!
User avatar
lmiltchev
Former Nagios Staff
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Error: Contactgroup 'linux-servers' is not defined anywh

Post by lmiltchev »

Can you post the "/usr/local/nagios/etc/servers/iceINT.cfg" config?

Also, run the following commands, and show the output:

Code: Select all

grep -R "linux-servers" /usr/local/nagios/etc/
grep "/usr/local/nagios/etc/servers" /usr/local/nagios/etc/nagios.cfg
Be sure to check out our Knowledgebase for helpful articles and solutions!
kellyangell
Posts: 18
Joined: Mon Aug 08, 2016 3:20 am

Re: Error: Contactgroup 'linux-servers' is not defined anywh

Post by kellyangell »

Thanks for your response, i am running ubunutu and core version 4.1 enfact i read on your forum another similar problem and it said to either define the contact group or remove all references to that.
this seemed to work and i was able to reload the nagios daemon.

thanks for your help, I'm sure ill be in touch again soon.
kelly
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Error: Contactgroup 'linux-servers' is not defined anywh

Post by tmcdonald »

Great! Is it alright if we close this thread now?
Former Nagios employee
Locked