Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
2.0k views
in Technique[技术] by (71.8m points)

grafana - How to send alerts everytime it reaches a value

Im trying to figure out how I can send notification to myself everytime I reach a special value etc:

Status

As you can see I have set a alert option on 60MB and whenever I use speedtest. It should trigger a notification telling me that I have reached the trigger alert.

For some reason it doesnt and there is a huge potential that the issue can be me.

This is the settings I am using:

{
  "firing": false,
  "state": "ok",
  "conditionEvals": "false = false",
  "timeMs": "128.573ms",
  "logs": [
{
  "message": "Condition[0]: Query",
  "data": {
    "from": 1609935815283,
    "queries": [
      {
        "refId": "A",
        "model": {
          "alias": "$hostname: $col",
          "dsType": "influxdb",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "orderByTime": "ASC",
          "policy": "default",
          "query": "SELECT mean("Bytes_Received_persec") AS "Bytes Received persec", mean("Bytes_Sent_persec") AS "Bytes Sent persec" FROM "win_net" WHERE "host" =~ /$hostname$/ AND "instance" =~ /$network$/  AND $timeFilter GROUP BY time($interval), "host", instance fill(linear)",
          "rawQuery": true,
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "tags": []
        },
        "datasource": {
          "id": 7,
          "name": "InfluxDBTest"
        },
        "maxDataPoints": 0,
        "intervalMs": 0
      }
    ],
    "to": 1609935825283
  }
},
{
  "message": "Condition[0]: Query Result",
  "data": {
    "series": []
  }
},
{
  "message": "Condition: Eval: false, Query Returned No Series (reduced to null/no value)",
  "data": null
}
  ]
}

Image2 Image3 Image4

How can I get notification on Discord whenever in my case reaches 60MB of network data?


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...