Page 3 of 6

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 10:06 am
by scottwilkerson
Fix has been applied to the XI 2014 TRUNK and is undergoing testing.

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 10:58 am
by Hossy
scottwilkerson wrote:Now I understand what you are saying.

I will add this to our internal TODO, I believe I know how we can accomplish it, but it will be a major change that will require significant testing...
Thanks, Scott. When you have it, could you give me a bug ID or some identifier to (quickly) ask about the status of the fix in the future?

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 11:05 am
by scottwilkerson
I don't have a "bug ID", but it will be in 2014. However the changes were pretty straight forward, if you want I will attach what needs to be changed here to apply to a 2012 install if you would like to test it...

Install this CCM through Admin -> Manage Components
ccm.zip
unzip this file and place in /usr/local/nagiosxi/scripts
nagiosql_exportall.zip

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 11:13 am
by Hossy
scottwilkerson wrote:I don't have a "bug ID", but it will be in 2014. However the changes were pretty straight forward, if you want I will attach what needs to be changed here to apply to a 2012 install if you would like to test it...

Install this CCM through Admin -> Manage Components
ccm.zip
unzip this file and place in /usr/local/nagiosxi/scripts
nagiosql_exportall.zip
Is this a replacement for your earlier ccm.zip or in addition?

Is there a way to rollback the changes if it fails or doesn't fix the problem? (I haven't messed with Manage Components yet)

EDIT: We're running Nagios XI 2012R1.8

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 1:37 pm
by lmiltchev
Is this a replacement for your earlier ccm.zip or in addition?
Yes, it is a replacement.
Is there a way to rollback the changes if it fails or doesn't fix the problem? (I haven't messed with Manage Components yet)
Yes. You can install the previous ccm component by going to Admin->Manage Components->Browse...->Upload Component

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 3:31 pm
by Hossy
lmiltchev wrote:Yes. You can install the previous ccm component by going to Admin->Manage Components->Browse...->Upload Component
Where do I get the current ccm? I presume there's a way to download it from XI? or is it stored on the file system somewhere?

EDIT: Under Manage Components, there's no download link for CCM like there are on others.

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 4:01 pm
by lmiltchev
If you installed the ccm.zip that was provided by scottwilkerson (Tue Jan 28, 2014 1:17 pm; page 2), you can re-download it and install it.

If you haven't installed it but you want to save the current ccm, you can probably zip all of the files in the "/usr/local/nagiosxi/html/includes/components/ccm" directory as "ccm.zip", and install it later if you need to.

Re: Deactivated Hosts Aren't Removed from Core

Posted: Wed Jan 29, 2014 4:07 pm
by Hossy
lmiltchev wrote:If you installed the ccm.zip that was provided by scottwilkerson (Tue Jan 28, 2014 1:17 pm; page 2), you can re-download it and install it.

If you haven't installed it but you want to save the current ccm, you can probably zip all of the files in the "/usr/local/nagiosxi/html/includes/components/ccm" directory as "ccm.zip", and install it later if you need to.
Ah, ok. So the ZIP file is just a copy of the /usr/local/nagiosxi/html/includes/components/ccm directory. Sure, I just zip that up before testing the new ccm.zip. Thanks for the info!

I'm presuming the second ZIP file fixes the Apply Configuration issue (the second issue listed)?

Re: Deactivated Hosts Aren't Removed from Core

Posted: Thu Jan 30, 2014 9:43 am
by scottwilkerson
Hossy wrote:Ah, ok. So the ZIP file is just a copy of the /usr/local/nagiosxi/html/includes/components/ccm directory. Sure, I just zip that up before testing the new ccm.zip
perfect
Hossy wrote: I'm presuming the second ZIP file fixes the Apply Configuration issue (the second issue listed)?
Correct, actually, they both do..

Re: Deactivated Hosts Aren't Removed from Core

Posted: Thu Jan 30, 2014 4:58 pm
by Hossy
scottwilkerson wrote:I don't have a "bug ID", but it will be in 2014. However the changes were pretty straight forward, if you want I will attach what needs to be changed here to apply to a 2012 install if you would like to test it...

Install this CCM through Admin -> Manage Components
ccm.zip
unzip this file and place in /usr/local/nagiosxi/scripts
nagiosql_exportall.zip
Unfortunately, this didn't fix the problem. I was still able to deactivate a host that I know would cause an invalid config. And, upon fixing the error after running Apply Configuration, the deactivated host CFG file was never deleted.

EDIT: I deactivated two hosts. One through the checkbox/list method and one through clicking on the host and unchecking the Active checkbox.