Page 1 of 1

Send scheduled report only if there are entries.

Posted: Wed Mar 06, 2019 5:15 pm
by johndorm
Hello, folks.

I want to lighten the email load of my alert recipients for WARNINGS. In my environment, WARNINGs are "This should be looked at" not "WAKE THE PRESIDENT!" events.

Generally, WARNINGS can wait a bit to get resolved while the CRTICALs are paged immediately.

My question has to do with reports.

I can create a scheduled "State History" report for the servicegroup that I care about and it works perfectly.

What I want to do is suppress that report if it is empty. I don't want to send a daily email that will start to be ignored in 5 days and have something of note in 6 days.

Is this doable? I'm not seeing any configuration options to suppress the email if the report is empty.

I already have a script that kicks off for criticals that inserts some info into a database to be scraped later for outage causing events that I could restructure to insert warning events into a separate table, but the reports are so close to being what I need, I figured I'd ask the question.

Thanks!

Re: Send scheduled report only if there are entries.

Posted: Thu Mar 07, 2019 12:30 pm
by benjaminsmith
Hi @johndorm,
Is this doable? I'm not seeing any configuration options to suppress the email if the report is empty.
Out of the box that's not something that can be currently done with the scheduled reports. One possibility is to use host or service escalations to direct warning notifications to one group of contacts and critical notifications to another.

Understanding Nagios XI Notification Escalations

Re: Send scheduled report only if there are entries.

Posted: Thu Mar 07, 2019 12:38 pm
by johndorm
One possibility is to use host or service escalations to direct warning notifications to one group of contacts and critical notifications to another.
Yep, already doing that on the services themselves.

I'll just modify the one I have that stores criticals in a table to do the same with warnings and then run a chron job to email the alerts from the past 24 hours.

Thanks! You can lock this post.

Re: Send scheduled report only if there are entries.

Posted: Thu Mar 07, 2019 12:40 pm
by benjaminsmith
Hi @johndorm,
Thanks! You can lock this post.
Closing. Thank your for using the Nagios Support Forum.