chronograf icon indicating copy to clipboard operation
chronograf copied to clipboard

Some Kapacitor alerts are not getting triggered.

Open kumudt opened this issue 9 years ago • 6 comments

I am using Chronograf 1.3.0, Kapacitor 1.2.0 and Influx 1.2.2

I created a Kapacitor SMTP alert in Chronograf and configured Kapacitor with a working SMTP endpoint. I am able to see the alert getting triggered in the alert history but unable to receive the email. For some alerts, even the alert is not getting triggered (not shown in alert history) even though it is supposed to (from the data).

What is going wrong in here?

kumudt avatar May 10 '17 11:05 kumudt

Hi kumudt,

Thanks for reporting this, I'll look into it shortly.

imogenkinsman avatar May 10 '17 18:05 imogenkinsman

@kumudt I am using the same versions and has managed to send email alerts through gmail smtp. Setup done in Chronogaf too. Take a view on the Kapacitor log eventually .

jensoleg avatar May 11 '17 07:05 jensoleg

I used this Query to create a test alert.

SELECT mean("cpu_usage_nanocores") AS "mean_cpu_usage_nanocores" FROM "telegraf"."autogen"."kubernetes_node" WHERE time > now() - 15m GROUP BY time(5m0s)

Rule Condition was:

cpu_usage_nanocores is greater than 100000000 (100M) which is always true in our case (I can even see that in that graph).

These are the logs from kapacitor whenever I create / update an alert.

2017-05-11T08:25:27.001990342Z [httpd] 100.96.3.20 - - [11/May/2017:08:25:26 +0000] "GET /kapacitor/v1/tasks/chronograf-v1-7bfaea2d-30f2-41de-9db7-0262ce148662?dot-view=attributes&replay-id=&script-format=formatted HTTP/1.1" 200 1358 "-" "KapacitorClient" 62e2a539-3623-11e7-91a3-000000000000 104839
2017-05-11T08:25:27.48971061Z [task_master:main] 2017/05/11 08:25:27 I! Stopped task: chronograf-v1-7bfaea2d-30f2-41de-9db7-0262ce148662
2017-05-11T08:25:27.50149966Z [httpd] 100.96.3.20 - - [11/May/2017:08:25:27 +0000] "PATCH /kapacitor/v1/tasks/chronograf-v1-7bfaea2d-30f2-41de-9db7-0262ce148662 HTTP/1.1" 200 1018 "-" "KapacitorClient" 632f9d59-3623-11e7-91a4-000000000000 110320
2017-05-11T08:25:27.605302931Z [task_master:main] 2017/05/11 08:25:27 I! Started task: chronograf-v1-7bfaea2d-30f2-41de-9db7-0262ce148662
2017-05-11T08:25:27.788486638Z [httpd] 100.96.3.20 - - [11/May/2017:08:25:27 +0000] "PATCH /kapacitor/v1/tasks/chronograf-v1-7bfaea2d-30f2-41de-9db7-0262ce148662 HTTP/1.1" 200 1253 "-" "KapacitorClient" 63410dbf-3623-11e7-91a5-000000000000 282464
2017-05-11T08:25:30.008271796Z [httpd] 100.96.3.17 - - [11/May/2017:08:25:30 +0000] "POST /write?consistency=&db=_internal&precision=ns&rp=monitor HTTP/1.1" 204 0 "-" "InfluxDBClient" 64be89ea-3623-11e7-91a6-000000000000 2657

I see nothing scary in those logs. If the alert was configured properly, why couldn't I see the alert being triggered in alert history. There are some other Kapacitor alerts which are working as expected. I mean we could see the alerts in the alert history.

I agree that there was something wrong with the SMTP credentials that we are using. So, getting this log message.

2017-05-11T08:32:50.657795684Z [smtp] 2017/05/11 08:32:50 E! gomail: could not send email 1: 554 Message rejected: Email address is not verified. The following identities failed the check in region US-WEST-2: [email protected]

We will fix them. But there was some issue in triggering the above-mentioned alert. Do you guys have any idea about what was going wrong in there??

kumudt avatar May 11 '17 08:05 kumudt

The rule is always true ? Then it won't get triggered. Try setting up a rule that WILL trigger

jensoleg avatar May 11 '17 09:05 jensoleg

@jensoleg thanks for the reply.

Let me test that and get back to you.

kumudt avatar May 11 '17 09:05 kumudt

Closing this. Not able to provide exact steps to reproduce this issue. All other alerts are working except for the case that I described above. Even when I increased the cpu_usage_nanocores to 400M and changed the group by time to 10 sec alert is not getting triggered.

kumudt avatar May 12 '17 12:05 kumudt