Page 1 of 1

Any way to get an alert that my notfications are disabled?

Posted: Thu Feb 09, 2017 3:01 pm
by kelemvor
When we do patching or other system maintenance, we generally go into Nagios and Disable all notifications from the Process Info page.
System | Process Info| Disable Notifications

However, we've had times in the past where someone has forgotten to go back in and turn notifications back on when they were done which is a problem. Is there any way that we can configure something so that it all notifications are disabled I can get a reminder email every so often telling me that my notifications are disabled?

Or is there any way to Disable All Notifications for a certain length of time and have them turn back on after XX hours or anything like that?

Thanks.

Re: Any way to get an alert that my notfications are disable

Posted: Thu Feb 09, 2017 3:08 pm
by rkennedy
However, we've had times in the past where someone has forgotten to go back in and turn notifications back on when they were done which is a problem. Is there any way that we can configure something so that it all notifications are disabled I can get a reminder email every so often telling me that my notifications are disabled?
This wouldn't work, since you've globally disabled your notifications. If you have another Nagios machine, then you could parse the status.dat to see if notifications are turned on, and alert you accordingly.
Or is there any way to Disable All Notifications for a certain length of time and have them turn back on after XX hours or anything like that?
Built in, there isn't a way to do this, but it could probably be done with a bash script or CRON. If you have an idea for a new idea, feel free to post the feature here for Core - https://github.com/nagiosenterprises/nagioscore/issues

Re: Any way to get an alert that my notfications are disable

Posted: Mon Feb 13, 2017 10:30 am
by eloyd
There is a feature request for this type of functionality at https://github.com/NagiosEnterprises/na ... /issues/52

Re: Any way to get an alert that my notfications are disable

Posted: Mon Feb 13, 2017 12:22 pm
by kelemvor
So I see I can do a Scheduled Downtime for a Host Group. Is there an easy way to just create a HostGroup that contains All the hosts?

I tried doing a:
define hostgroup {
hostgroup_name AllHosts
members * (also tried hostgroup_members)
}

But after I did a restart the group didn't show up so not sure if that's the right syntax. We are still on Nagios 3.5.1 if that matters.

Thanks.

Re: Any way to get an alert that my notfications are disable

Posted: Mon Feb 13, 2017 5:36 pm
by rkennedy
Did you apply configuration after doing so? Your syntax looks correct, and just tested it over here -

Code: Select all

define hostgroup {
        hostgroup_name                          all hosts wildcard
        alias                                   all hosts wildcard
        members                                 *
        }
all-hosts-hg.PNG
all-hosts-hg.PNG (13.51 KiB) Viewed 3330 times
My guess is you could have other hostgroups or templates interfering.

Re: Any way to get an alert that my notfications are disable

Posted: Wed Mar 01, 2017 2:26 pm
by tmcdonald
Just checking in since we have not heard from you in a while. Did @rkennedy's post clear things up or has the issue otherwise been resolved?

Re: Any way to get an alert that my notfications are disable

Posted: Wed Mar 01, 2017 2:54 pm
by kelemvor
We ended up just parsing the status file to see if notifications are off and have a cron job that sends us an email every hour if it notices they are off.

Thanks.