Can anyone provide a better description of how the conditions work. I’m having a hard time understanding what the 5m,now portion is doing. I’ve read the alerting Grafana documentation and it doesnt give a clear description either. Thanks in advance for your help!
it’s the time range for the query, (from, to), so from 5m (ago) to now
This condition means: if the query A has a max value above 95 between now and 5 minutes ago.
You could for example compare between 20 minutes ago and 5 minutes ago like this:
Thanks for that info.
I have one more query plz.
For now A stands for first query in the metric, so in my Grafana panel I have added the servers one by one and the rows are from A to I to show the RAM utilization graph.
How I can include the queries from A to I in one condition so that which ever server cross the threshold will trigger the email alert. (eg like Query(A-I, 5m,now) or so)
And to generate an email (SMTP), do I need to make any setting changes?
Why are you creating a query for every host instead of using a wildcard or regex and just having one query?
For a email, you have to configure SMTP: Configure Grafana | Grafana documentation
And you have to add a notification channel: Configure notification policies | Grafana documentation
Thanks a lot Daniel for your reply.
Can you please through some insight on how I can use a wildcard or regex to have one query from all the hosts in a single dashboard panel.
I have 8 server nodes in one Hyper-V cluster and Telegraf is running from all these 8 nodes.
I created a RAM utilization graph and added the metrics from all these 8 hosts (as shown in the above snapshot) and I am using InfluxDB as datasource.
Here is an example from another question and here is an example from my local Grafana:
In your case, you would have one query and the where clause would look something like this:
WHERE "host" =~ /dexxxxx*/
There are only a few sentences on regular expressions in the InfluxDB documentation.