Page 1 of 4

Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 9:00 am
by JakeHatMacys
I was changing some of the host commands on our hosts and got a random configuration error that has nothing to do with what I was changing:

Code: Select all

Waiting for configuration verification................................................................................................................................................................................................................................................................................................................................................
There was an error while attempting to apply configuration. Error code: 254.

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.

View a snapshot of this configuration error

Show Config Changes

Error: Impossible service dependency definition
Ran the Write Config Utility and have no errors.... And I also deleted all Service Dependencies that were there (they'd been there for months) and still getting the same error when applying config and still no errors when running the write config tool. I'm running version 2014 2.5

Code: Select all

Checked 2048 hosts. 
	Checked 5 host groups. 
	Checked 3 service groups. 
	Checked 10 contacts. 
	Checked 2 contact groups. 
	Checked 123 commands. 
	Checked 16 time periods. 
	Checked 0 host escalations. 
	Checked 0 service escalations. 
Checking for circular paths... 
	Checked 2048 hosts 
	Checked 5 service dependencies 
	Checked 0 host dependencies 
	Checked 16 timeperiods 
Checking global event handlers... 
Checking obsessive compulsive processor commands... 
Checking misc settings... 

Total Warnings: 7419 
Total Errors: 0 

Things look okay - No serious problems were detected during the pre-flight check 
The Monitoring engine also appears to be bombing out now.
Capture.JPG
Thoughts?????

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 11:14 am
by jdalrymple
JakeHatMacys wrote:And I also deleted all Service Dependencies that were there (they'd been there for months) and still getting the same error when applying config and still no errors when running the write config tool.
Unfortunately sometimes the sanity check misses stuff.

You said you deleted your Service Dependencies - from CCM or from the filesystem?

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 12:13 pm
by JakeHatMacys
jdalrymple wrote:
JakeHatMacys wrote:And I also deleted all Service Dependencies that were there (they'd been there for months) and still getting the same error when applying config and still no errors when running the write config tool.
Unfortunately sometimes the sanity check misses stuff.

You said you deleted your Service Dependencies - from CCM or from the filesystem?
From CCM. I don't believe at all that this is a configuration issue, I was only changing host commands... I have since took off the few changes I made. And still when applying configuration it just sits there and thinks for a while going "............................................................................................................"

Then eventually comes back with some 254 error and then when taking a closer look says impossible service dependency.

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 12:36 pm
by jdalrymple
JakeHatMacys wrote:Ran the Write Config Utility and have no errors....
Did you do the full gamut?

Delete, Write, Verify, Restart?

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 12:55 pm
by JakeHatMacys
Fairly uncomfortable hitting delete... what does that actually delete???

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 12:58 pm
by abrist
All host and service configs in:

Code: Select all

/usr/local/nagios/etc/hosts/
/usr/local/nagios/etc/services/
Do not worry - these are generated by the CCM, so they will all be re-written on an apply config/ "write" tools button.
I would suggest not using the tool's "Restart" button as that works outside of the snapshot system, nor will it check config verification before trying to restart nagios.

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 1:26 pm
by JakeHatMacys
abrist wrote:All host and service configs in:

Code: Select all

/usr/local/nagios/etc/hosts/
/usr/local/nagios/etc/services/
Do not worry - these are generated by the CCM, so they will all be re-written on an apply config/ "write" tools button.
I would suggest not using the tool's "Restart" button as that works outside of the snapshot system, nor will it check config verification before trying to restart nagios.
Well It didn't exactly work, I lost 1500 hosts and while everything in the Write Config area works fine... The actual apply config in CCM still hoses up. At this point with my manager glaring at me I had to run a restore.

So not sure what caused the issue but hopefully the restore fixes it...

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 1:28 pm
by JakeHatMacys
jdalrymple wrote:
JakeHatMacys wrote:Ran the Write Config Utility and have no errors....
Did you do the full gamut?

Delete, Write, Verify, Restart?
Also is there a specific order to run these in? I just went top down when I did it.

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 1:39 pm
by abrist
That should be fine (though I would suggest using apply config instead of "restart"). Is it still misbehaving?

Re: Nagios XI Configuration Random Configuration Error

Posted: Wed Apr 08, 2015 1:45 pm
by JakeHatMacys
abrist wrote:That should be fine (though I would suggest using apply config instead of "restart"). Is it still misbehaving?
Yep same error :(

So something is definitely hosed somewhere... The config wasn't erroring at all earlier today or on 4/6 where the back up is from.