Page 1 of 1

Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 7:21 am
by blariv
Hi,

I have to open this up again as it has not been resolved as I thought.

I have a strange issue. whenever we apply the config it will fail, however when you check the config snapshots it does not show the one you just ran w/ the error.

I find now if I do a database repair then restart the nagios service this temporally fixes the issue.

An error occurred while attempting to apply your configuration to Nagios Core. Monitoring engine configuration files have been rolled back to their last known good checkpoint.

Nagios XI Version : 2012R2.7
nagiosxi.hasbro.com 2.6.32-573.26.1.el6.x86_64 x86_64
CentOS release 6.7 (Final)

Re: Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 8:00 am
by scottwilkerson
By any chance are you running out of disk space?

Code: Select all

df -h
When you get the error can you run the following from the command line and apply the configuration while you do so

Code: Select all

tail -f /usr/local/nagiosxi/var/cmdsubsys.log > /tmp/cmdsubsys.log
Then after you get the error attach the /tmp/cmdsubsys.log to this post

Re: Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 8:54 am
by blariv
space is good, about 21GB available.

output is attached.

Re: Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 9:14 am
by scottwilkerson
Ok, it is having problems writing the configuration files.

Can you post the following file so we can see more details
/usr/local/nagiosxi/scripts/nagiosql.export.monitoring

Again thanks

Re: Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 10:40 am
by blariv
attached

Re: Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 12:09 pm
by scottwilkerson
blariv wrote:attached
I think it didn't get attached

Re: Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 12:15 pm
by blariv
sorry, now attached

Re: Applying Configuration Failure - ReOpen

Posted: Thu Sep 07, 2017 12:24 pm
by scottwilkerson
Ok, based on this file, the applying of configuration is getting cutoff by the max_execution_time in /etc/php.ini

lets edit /etc/php.ini and set

Code: Select all

max_execution_time = 300
then restart httpd

Code: Select all

service httpd restart
and try to apply the config again.

One thing I'd like to point out is that in newer versions of Nagios XI the Apply config time is dramatically reduced, and instead of waiting 4 minutes it may be 20 seconds to complete

This is on top of hundreds of other improvements and security fixes. I would highly suggest working toward upgrading if at all possible.

Re: Applying Configuration Failure - ReOpen

Posted: Mon Sep 11, 2017 7:58 am
by blariv
that seems to have fixed it thank you!

I also have the new version installed and am in process of migrating.

please lock this.

Re: Applying Configuration Failure - ReOpen

Posted: Mon Sep 11, 2017 8:39 am
by scottwilkerson
Glad that was successful!