10 Jun 2024
01:56 PM
- last edited on
18 Jun 2024
01:42 PM
by
Michal_Gebacki
i need to create metric event where disk free between 10%- 20% . tried with some metrics . but not working
following return no data
builtin:host.disk.available:filter(host.disk.available> 10):splitBy("dt.entity.host",dt.entity.disk):sort(value(auto,descending))
and more over how ti reference disk name .if i want exclude certain disk from monitoring
10 Jun 2024 08:04 PM
Not possible to have such logic in the metric query.
What you can do is create a warning metric event if the threshold passes de 20% threshold, and once it is less than 10% you send out a critical one.
This requires 2 separate metric events, but these will just be 2 metric-selector-based configurations.
https://docs.dynatrace.com/docs/shortlink/metric-events-metric-selector-events
These events may be filtered by an alerting profile that triggers just an email or slack to inform about a warning, or in the critical case could open up a ticket, this is just an example.
11 Jun 2024 03:45 AM - edited 11 Jun 2024 05:45 AM
1. //metric event if the threshold passes de 20%// how can i set it .
for example i keep 1. warning < 20 % and 2. critical for <10% . can i set order or metricevent execution.
will this work 1. builtin:host.disk.free:filter(and(in("dt.entity.host", entitySelector("type(~"HOST~"),entityName(~"xxxx~")")),series(value,ge(77)),series(value,lt(90))))
2. builtin:host.disk.free:filter(and(in("dt.entity.host", entitySelector("type(~"HOST~"),entityName(~"xxxx~")")),series(value,gt(77))))
And one more question. how can i add tags or custom metric data into alert description .
i need customer metric for specific servers, specific mount point on some server.
will all metric event evaluated always for all metrics
11 Jun 2024 12:02 PM
You can add event properties which you can use to filter these events in an alerting profile or further down the line if forwarded to any ITSM.