Delete Scheduled Downtime for entire Host Group

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
jflanders
Posts: 2
Joined: Tue May 22, 2012 7:04 am

Delete Scheduled Downtime for entire Host Group

Post by jflanders »

Hello, I've been approached by my manager to see if its possible to delete scheduled downtime for an entire houst group rather then a single host at a time. On weekends we schedule downtime to a host group before weekend maitenance sometimes the tech finishes early but currently we have to wait for the downtime to finish or manually delete hundreds individually. We were running 3.2.3 but when I saw the enhancement notes for 3.3.1 we were hoping to take advantage of this listed feautre:

Downtime delete commands made "distributable" by deleting by host group name, host name or start time/comment (Opsview team)

I upgraded our Nagios server but can't find any additional functions to delete downtimes by host group name, can someone explain to me what I'm missing and how this can be accomplished, thanks.
agriffin
Posts: 876
Joined: Mon May 09, 2011 9:36 am

Re: Delete Scheduled Downtime for entire Host Group

Post by agriffin »

I don't believe this is functionality that comes with Nagios Core. You could write a script to do this using Nagios' external command pipe, though.
jflanders
Posts: 2
Joined: Tue May 22, 2012 7:04 am

Re: Delete Scheduled Downtime for entire Host Group

Post by jflanders »

That could work and I understand if this enhancement is in command line only but when I followed your link ultimately to the external commands for Deleting Downtime its only discusses using downtime_id and nothing about using host group name or host name which I could use in a script.
DEL_HOST_DOWNTIME

Command Format:
DEL_HOST_DOWNTIME;<downtime_id>
Has the documentation not been updated with this feature? I find that odd considering its been in place for almost a year.

Has anyone had any experience with using exernal commands to delete the scheduled downtime for a list of known hosts or a host group?
agriffin
Posts: 876
Joined: Mon May 09, 2011 9:36 am

Re: Delete Scheduled Downtime for entire Host Group

Post by agriffin »

Hmm... you're right. It seems like you can schedule downtime by hostgroup but not cancel it. I'm not sure what the best option is then. Maybe you could search your config files with awk or something to build a list of hosts in a hostgroup?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Delete Scheduled Downtime for entire Host Group

Post by scottwilkerson »

Not specifically by hostgroup, but...

Mass deletion of downtimes has just been added to the Mass Acknowledge component (v1.6)

http://assets.nagios.com/downloads/nagi ... wledge.zip
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked