Page 1 of 1
Removed a Contact and Now Cannot Save Config
Posted: Fri Sep 03, 2021 1:31 pm
by omarrrthepirate
I'm getting an error in our config after removing an employee who just left. Here is the error:
Error: Contact 'jwise' is not defined anywhere!
Error: Could not add contact 'jwise' to host (config file '/usr/local/nagios/etc/hosts/Clearpass.cfg', starting on line 16)
I suspect if I fix this one, it's just going to go to the next endpoint for which he was a contact and on and on. How can I fix this?
Thank you forum rockstars!
Re: Removed a Contact and Now Cannot Save Config
Posted: Fri Sep 03, 2021 2:29 pm
by pbroste
Hello ommarrrthepirate
Let's go ahead and reindex the Core Configuration Manager (CCM) configs by:
- 1: command list all running /bin/nagios -> ps -aux | grep -E '/bin/nagios'
[list]
[*]2: command -> killall -9 nagios (or pkill nagios)[/*]
[*]3: command -> rm -rf /usr/local/nagios/etc/import/*[/*]
Code: Select all
rm -rf /usr/local/nagios/etc/import/*
[*]4: Restart nagios.service by terminal command: -> systemctl restart nagios[/*]
[*]5:
Head over to the Nagios XI web console ==> Core Configuration Manager (CCM) ==> Config File Management ==> [Delete Files] ==> [Write Files] ==> [Verify Files][/*]
[*]6:
Core Configuration Manager (CCM) ==> Under Quick Tools ==> "Apply Configuration"[/*]
[*]7: Restart nagios.service by terminal command: -> systemctl restart nagios[/*]
[/list]
Verify that the host and services look good and verify that there are no errors in core by:
Code: Select all
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Issue persists, please PM your system profile for us to review updates.
To send us your system profile.
- Login to the Nagios XI GUI using a web browser.
- Click the "Admin" > "System Profile" Menu
- Click the "Download Profile" button
- Save the profile.zip file and share
Thanks,
Perry
Re: Removed a Contact and Now Cannot Save Config
Posted: Fri Sep 03, 2021 4:39 pm
by pbroste
Hello @omarrrthepirate
We see that there is a 'jwise' User setup, but in this case, to satisfy the condition we will need to create a contact for 'jwise'. We don't see that 'jwise' is added to 'usr/local/nagios/etc/contacts.cfg', by heading over to Core Configuration Manager > Contacts > Add New
Then rinse repeat if necessary from my previous post in this thread.
Thanks,
Perry
Re: Removed a Contact and Now Cannot Save Config
Posted: Thu Oct 07, 2021 4:33 pm
by hillhealthcenter
I had the same issue. I just recreated the contact to get the error to go away. We have yet to upgrade to the current release of XI.
Re: Removed a Contact and Now Cannot Save Config
Posted: Fri Oct 08, 2021 11:12 am
by pbroste
Hello @omarrrthepirate
Checking in with you to see if the previous post by @hillhealthcenter worked for you?
hillhealthcenter wrote:I had the same issue. I just recreated the contact to get the error to go away. We have yet to upgrade to the current release of XI.
Thanks,
Perry