Page 1 of 2

Nagios Apply Configuration Is Not Working

Posted: Wed Oct 19, 2016 12:07 am
by steelwedge
Dear Team,

We added a new host in CCM and clicked on apply configuration, it is spinning from last 24 hours and no update yet. Please let us know where to check the status and error for this.

-Mohan

Re: Nagios Apply Configuration Is Not Working

Posted: Wed Oct 19, 2016 1:14 am
by Box293
Can you please check this KB article and let us know if it fixes your problem:

https://support.nagios.com/kb/article.php?id=34

Re: Nagios Apply Configuration Is Not Working

Posted: Fri Oct 21, 2016 1:07 am
by steelwedge
When we run the ./reconfigure_nagios.sh script, we are getting NAGIOSQL LOGIN FAILED! message at the end. Please check and advise the next steps ASAP.


[nagios@swnagios root]$ cd /usr/local/nagiosxi/scripts
[nagios@swnagios scripts]$ ./reconfigure_nagios.sh
URL: http://localhost/nagiosxi/includes/components/ccm/
CMDLINE
/usr/bin/wget --save-cookies nagiosql.cookies --keep-session-cookies http://localhost/nagiosxi/includes/components/ccm/ --no-check-certificate --post-data 'submit=Login&hidelog=true&loginSubmitted=true&username=nagiosxi&password=n@gweb' -O nagiosql.login--2016-10-20 23:04:54-- http://localhost/nagiosxi/includes/components/ccm/
Resolving localhost... ::1, 127.0.0.1
Connecting to localhost|::1|:80... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://swnagios.test.steelwedge.com/na ... nents/ccm/ [following]
--2016-10-20 23:04:54-- https://swnagios.test.steelwedge.com/na ... nents/ccm/
Resolving swnagios.test.steelwedge.com... 10.101.16.16
Connecting to swnagios.test.steelwedge.com|10.101.16.16|:443... connected.
WARNING: cannot verify swnagios.test.steelwedge.comâs certificate, issued by â/C=US/ST=California/L=Pleasanton/O=Steelwedge Software/OU=CloudIT/CN=swnagios.test.steelwedge.com/emailAddress=[email protected]â
Self-signed certificate encountered.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: ânagiosql.loginâ

[ <=> ] 12,123 --.-K/s in 0s

2016-10-20 23:04:55 (24.2 MB/s) - ânagiosql.loginâ

NAGIOSQL LOGIN FAILED!

Re: Nagios Apply Configuration Is Not Working

Posted: Fri Oct 21, 2016 9:16 am
by rkennedy
Could you post a few things for us to look at?
- A screenshot of your system settings page
- A copy of your /etc/hosts
- Lastly, please attach your /etc/httpd/conf.d/ssl.conf

Re: Nagios Apply Configuration Is Not Working

Posted: Sat Oct 22, 2016 1:09 am
by steelwedge
PFA rar files has the requested details.

Re: Nagios Apply Configuration Is Not Working

Posted: Mon Oct 24, 2016 11:42 am
by rkennedy
Not sure where it's pulling the swnagios.test.steelwedge.com hostname from - are you using a proxy at all in your environment?

In your hosts file I noticed this -

Code: Select all

10.101.32.41	nagiostest.test.steelwedge.com nagiostest
10.101.32.42	nagiostest-ext.test.steelwedge.com nagiostest-ext
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
Please change it to be the following -

Code: Select all

10.101.32.41	
10.101.32.42	nagiostest-ext.test.steelwedge.com nagiostest-ext
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4 nagiostest.test.steelwedge.com nagiostest
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
Then, try once again. If it does not work, show us the output of reconfigure_nagos.sh once again.

Re: Nagios Apply Configuration Is Not Working

Posted: Tue Oct 25, 2016 8:27 am
by steelwedge
We corrected the hostname however we are facing the same issue, PFA screenshot of the host file. We restarted the nagios service also.

Re: Nagios Apply Configuration Is Not Working

Posted: Tue Oct 25, 2016 10:13 am
by rkennedy
Can you run the reconfigure once again and show us the result? Are you using a proxy at all in your environment?

Re: Nagios Apply Configuration Is Not Working

Posted: Tue Oct 25, 2016 11:48 am
by steelwedge
Below is the output, I will check and update on proxy.

[root@nagiostest ~]# cd /usr/local/nagiosxi/scripts
[root@nagiostest scripts]# ./reconfigure_nagios.sh
URL: http://localhost/nagiosxi/includes/components/ccm/
CMDLINE
/usr/bin/wget --save-cookies nagiosql.cookies --keep-session-cookies http://localhost/nagiosxi/includes/components/ccm/ --no-check-certificate --post-data 'submit=Login&hidelog=true&loginSubmitted=true&username=nagiosxi&password=n@gweb' -O nagiosql.login--2016-10-25 09:45:36-- http://localhost/nagiosxi/includes/components/ccm/
Resolving localhost... 127.0.0.1, ::1
Connecting to localhost|127.0.0.1|:80... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://nagiostest.test.steelwedge.com/ ... nents/ccm/ [following]
--2016-10-25 09:45:36-- https://nagiostest.test.steelwedge.com/ ... nents/ccm/
Resolving nagiostest.test.steelwedge.com... 127.0.0.1
Connecting to nagiostest.test.steelwedge.com|127.0.0.1|:443... connected.
WARNING: cannot verify nagiostest.test.steelwedge.comâs certificate, issued by â/C=US/ST=California/L=Pleasanton/O=Steelwedge Software/OU=CloudIT/CN=nagiostest.test.steelwedge.com/emailAddress=[email protected]â
Self-signed certificate encountered.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/html]
Saving to: ânagiosql.loginâ

[ <=> ] 20,104 129K/s in 0.2s

2016-10-25 09:45:37 (129 KB/s) - ânagiosql.loginâ

NAGIOSQL LOGIN FAILED!

Re: Nagios Apply Configuration Is Not Working

Posted: Tue Oct 25, 2016 1:13 pm
by avandemore
Are you running version 5.3.0? If so, can you upgrade to the bug fix only release 5.3.1 and try again?