dyadav
(Deepak Yadav)
October 5, 2021, 11:09pm
1
I have configured email alerts if CPU usage is above or equals 80% for last 2 minutes. Below is the content configured in my alert:
{{alertName}} - {{context.group}} is in a state of {{context.alertState}}
Reason:
{{context.reason}}
I am getting email when CPU usage is above 80% but the content is not correct in mail. Below is example email:
Non-Prod Infra Alerts -Hostname is in a state of ALERT
Reason: CPU usage is less than a threshold of 80 (current value is 99.3%)
It should say CPU usage is more than a threshold.
Please suggest.
weltenwort
(Felix Stürmer)
October 6, 2021, 9:31am
2
Hi @dyadav ,
could you tell us which version of the Elastic Stack you're seeing this in? I am trying to reproduce it on my end.
weltenwort
(Felix Stürmer)
October 6, 2021, 11:07am
3
It seems to be a known issue, which is tracked in Alert and Actions - context.reason shows wrong text · Issue #88585 · elastic/kibana · GitHub . Thanks for bringing it to our attention again! Since the fix looked trivial I created a PR for it at [Metrics UI] Fix metric threshold alert reason message for gte/lte comparator by weltenwort · Pull Request #114080 · elastic/kibana · GitHub .
This problem only seems to occur for the "less/greater or equal" case. Until the fix is merged and released you could try to work around it by using the "greater than" with a slightly smaller threshold (e.g. 79% instead of 80%).
weltenwort
(Felix Stürmer)
October 7, 2021, 2:54pm
4
The fix has been merged and should hopefully be released in 7.15.1.
1 Like
dyadav
(Deepak Yadav)
October 12, 2021, 4:30pm
5
Thank you so much Felix for the update. I have configured using the work around for now.
Will wait for it to be released in new version.
system
(system)
Closed
November 9, 2021, 4:30pm
6
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.