How to retrieve only parent downtimes

Hi icinga community,

My setup: icinga2 2.15.1, icingaweb 2.12.6, icingadb 1.3.0

The problem I am trying to solve is as follows: I schedule a downtime in a recursive way (example, in a linux host with lots of services, lot of Oracle databases or Weblogic servers, etc etc):

After that, my teammates need to to review the scheduled downtimes, but they do not care on the children objects (databases or weblogic servers) only in the parent one (the linux host). To accomplish that, I build a icingaweb dashboard with a custom filter, but I am unable to get exactly what objects have a null parent_id in the downtime hierarchy:

Is there any way to get this in a icingaweb2 dashboard?

Best regards

Jose G. Juanino

Hi,

I never worked with filtering on downtimes, but in similar situations my filters are usually “not equal to something”, i.e. “!=*”, because Icinga considers that nothing (null) does not match with something (*).

Give it a try, it might work in your case too.

Best regards,

Jean

NB: You may also inspect the object sources by exporting it via the command line, and look for the values of the property you want to filter on.

Hi Jean, thank you very much for your response. That suggestion works like a charm, and is exactly what I am looking for. Only a detail: the exact filter is

!~ *

instead of

!= *

The URL filter is:

icingadb/downtimes?downtime.parent_id!~*

That filter displays exactly the root nodes of the scheduled downtimes (they may be objects type Host or Service), without the noise of the dependent children (hosts or services). I find it very useful.

Regards

Jose G. Juanino