See https://www.robustperception.io/using-time-series-as-alert-thresholds
On Fri, 26 Feb 2021 at 14:16, Andrew Kulikov <[email protected]> wrote: > Hi, > > I have, for example, simple alert for low swap: > > name: Low swap > expr: swap_used_percent > 80 > for: 10m > labels: > severity: warning > annotations: > description: Swap usage is {{ $value | printf "%.2f" }}% on {{ > $labels.host }} > summary: Low swap > > For some hosts it's normal to use 50% of swap, for other hosts -- 90% of > swap. And I would like to define different thresholds for different hosts. > Can I define per-host threshold for swap usage write alert expression like > this? > > expr: swap_used_percent > {{ $swap_threshold }} > > Thanks a lot! > > -- > You received this message because you are subscribed to the Google Groups > "Prometheus Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/prometheus-users/13a55334-4548-4e03-b78e-56154fb6b4e1n%40googlegroups.com > <https://groups.google.com/d/msgid/prometheus-users/13a55334-4548-4e03-b78e-56154fb6b4e1n%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "Prometheus Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/CAP9KPhAkn0p4xHeZaA-0cGxFHx%2B1GdtiinX8kTZHvSm0kbvvkg%40mail.gmail.com.

