Page 1 of 1

Unable to add Host or Hostgroup to service

Posted: Wed Nov 18, 2020 5:15 am
by noweda
Hello support,

we are running a new NagiosXI installation to migrate our production system from CentOS 6 to CentOS 8.

Nagios XI - System Info
System
Nagios XI version: 5.7.5
Release info: ux010163.noweda.de 4.18.0-193.14.2.el8_2.x86_64 x86_64
CentOS Linux release 8.2.2004 (Core)
Gnome is not installed

Apache Information
PHP Version: 7.2.24
Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.132 Safari/537.36

In the new installation we are unable to add hosts or hostgroups to services. We can choose and assign them as usual, but when we save the service, the assignments are gone. When we change other things, like the service name for example, this is saved, but all host or hostgroup assignments to services are not.

Do you have any ideas?

If you need a profile.zip, please provide me a PM.

Best regards
Christoph

Re: Unable to add Host or Hostgroup to service

Posted: Wed Nov 18, 2020 5:27 pm
by dchurch
Sounds like there might be a database error.

If you PM me a system profile I can diagnose further. Get one by going to Admin (top menu) => System Profile (in the left menu), then clicking the blue button.

In the meantime, you can try running the database repair script

Re: Unable to add Host or Hostgroup to service

Posted: Wed Dec 02, 2020 10:28 am
by noweda
Sorry, for the delay in this case.

I executed the script "/usr/local/nagiosxi/scripts/repair_databases.sh" with success:

Code: Select all

===============
REPAIR COMPLETE
===============

=======================
nagios database repair succeeded
nagiosql database repair succeeded
nagiosxi database repair succeeded
Unfortunately, the issue still persists. System profile sent via pm.

Sincerely,
Pasqual

Re: Unable to add Host or Hostgroup to service

Posted: Wed Dec 02, 2020 12:41 pm
by dchurch
Next thing you could try is clearing the objects.cache file:

Code: Select all

rm /usr/local/nagios/var/objects.cache
service nagios restart

Re: Unable to add Host or Hostgroup to service

Posted: Thu Dec 03, 2020 2:46 am
by noweda
Hello dchurch,

I cleared the cache, but the issue persists.

Did you find any issues in the profile, Pasqual sent you? What can we do now? The system is not usable at the moment!

Best regards,
Christoph

Re: Unable to add Host or Hostgroup to service

Posted: Thu Dec 03, 2020 1:34 pm
by dchurch
The default settings for MySQL server in CentOS 8 changed. Refer to this doc to check/update the necessary setting.

https://support.nagios.com/kb/article/n ... s-780.html

Re: Unable to add Host or Hostgroup to service

Posted: Thu Dec 10, 2020 3:41 am
by noweda
Hello dchurch,

thank you for your reply. I tried that, but now I'm not able to open CCM "Services" nor "Hosts" anymore. When I click on Services or Hosts, the site does not open, but the browser stucks at "waiting for ux010163". I waited 1 hour, but the site does not open.

The same happens, when I try to download Nagios system profile...

Any ideas?

Best regards
Christoph

Re: Unable to add Host or Hostgroup to service

Posted: Thu Dec 10, 2020 5:40 am
by noweda
Hello dchurch,

sorry, the "waiting for" problem was related to an http and certificate problem. Now it works and with the mysql changes I'm able to attach hosts again.

Thank you for your help.

Best regards
Christoph