Page 1 of 1

Error applying configuration

Posted: Wed Oct 07, 2020 6:23 am
by ITmon
Good afternoon all

I removed a contact who had left the business recently and also makde some other changes - the apply configuration worked fine as it usually does.

Today I have attempted to remove a host which has gone, but now the apply configuration errors as follows:

Error - contact ''removed_contact_name'' is not defined anywhere

Error - could not add contact ''removed_contact_name'' to host (config file 'usr/local/nagios/etc/hosts/servername.cfg' starting on line 16)

clearly I need to edit this but not being a linux person, can someone tell me the easiest way to rectify my situation please? Nagios just runs in the background for us and we dont have what we would call a proper nagiosadmin to go to :-(

thanks in advance
Andy

Sorry - just to clarify - I have investigated the said servername.cfg via the GUI to see if any contact details somehow needed changing but couldn't see anything obvious!

Re: Error applying configuration

Posted: Wed Oct 07, 2020 4:21 pm
by benjaminsmith
Hi Andy,

Happy to help out. So it's trying to add a contact to the host that doesn't exist. Just double-check to make sure you have the correct contact settings for these hosts.
host-contact.png
Then run through the following steps in Configure > CCM > Tools > Config File Management

1. Delete Files
2. Write Files
3. Verify Files ( if you see any errors follow the message to correct and repeat steps 1-3 until it passes)
4. Restart Nagios Core

If you're not able to correct it, then run the following command, PM the nagiosql.sql file and I can test it out on my end. Thanks, Benjamin

Code: Select all

mysqldump -uroot -pnagiosxi nagiosql > nagiosql.sql