Page 1 of 1

Limit SLA Reports to only Failures

Posted: Mon Mar 01, 2021 11:11 am
by rexmundo
Hi

The customer wants us to tell him, using Nagios, which servers are experiencing a high load.
The "high load" concept is not defined but we thought we will define it based on CPU load.

We set an 80% warning and 90% critical limit on CPU metrics and put all CPU metrics in an "All_CPU" service group.

We can then run an SLA report on ALL_CPU group with say an SLA target of 85%.

So if a device had a high CPU for over 15% of the time it will fail SLA.

So far so good..

However the SLA report includes everything. With 5k devices it would generate a 400page PDF document.
200 for the host data and 200 for the service data (200x25=5k metrics).

Is there a way to limit the output to just the devices that failed the SLA? Or some other way to extract a report? (SQL query?)

rgds
George

Re: Limit SLA Reports to only Failures

Posted: Mon Mar 01, 2021 7:16 pm
by ssax
There's not currently a way to do it in the SLA report, I can request that development add this as a feature on your behalf if you'd like?

The only other method would be for you to script it out with the API, see here on your XI server:

Code: Select all

http://YOURXISERVER/nagiosxi/help/api-object-reference.php#objects-sla

Re: Limit SLA Reports to only Failures

Posted: Mon Mar 01, 2021 8:44 pm
by rexmundo
Hi ssax

Thanks that would be great.

I tried the SLA API option and it doesnt work as there is no show details option. It simply returns the overall SLA for the entire group. I need to see per object in that group, like you can do show details in the UI.

It would be great if:
1) In the UI, show details can be part of the options you can save in the report
2) You can omit host state as only interested in the service state.
3) You can filter from the report the services that do not meet the criteria.
4) Show details can be included in the API

At the moment the only way I could do this would be to simply query the members of a service group and then for each group member, collect their own individual SLA status. For 5k members, it will take a while.

Re: Limit SLA Reports to only Failures

Posted: Tue Mar 02, 2021 6:38 pm
by ssax
Sorry about that. There really isn't another way to get it at this time until development adds it.

I have created the requests:

Code: Select all

FR: XI - SLA Report - Add the option to only show failed SLA items
FR: XI - SLA Report - Add the option to only show host data or service data
FR: XI - SLA API Endpoint - Add showdetail option from SLA report/code]