Removed a Contact and Now Cannot Save Config

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
omarrrthepirate
Posts: 28
Joined: Fri Jul 09, 2021 1:13 pm
Location: Spokane, WA
Contact:

Removed a Contact and Now Cannot Save Config

Post 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!
Omarrr The Pirate!
Arrrrr
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Removed a Contact and Now Cannot Save Config

Post 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]
  • Code: Select all

    ps -aux | grep -E '/bin/nagios'
[*]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
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Removed a Contact and Now Cannot Save Config

Post 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
hillhealthcenter
Posts: 174
Joined: Fri Sep 21, 2012 7:45 am
Location: New Haven, CT

Re: Removed a Contact and Now Cannot Save Config

Post 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.
Thanks so much,
Tom
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Removed a Contact and Now Cannot Save Config

Post 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
Locked