Cardinality Rule not working #219
-
Hi All, I've recently installed Elastalert2 on RHEL7 server, tested few rules & its working as expected! We've been using custom scripts for each alert but this seemed way better solution! But I'm unable to implement the Cardinality rule, my use case is pretty basic - I need an alert if any value in a field exceeds the threshold in last 10mins.
Loglevel could be one of INFO, ERROR or WARN, and if any of these occur more than 10 times in last 4hours, an alert should be triggered.
I've gone through lots of open/closed issues, tried multiple suggested solutions, but somehow cant make it work(trying for more than 2 days now)! The use case seems pretty straightforward for Elastalert2 I believe but I'm missing something, can anyone please help me debug or share a sample that I can refer maybe? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 11 replies
-
Cardinality is the measure of unique values for a given field. So the only way it would trigger is if you had 10 different log levels show up in a 4 hour timeframe. Ex: INFO, DEBUG, ERROR, WARN, TRACE, FATAL, VERBOSE, XXX, YYY, ZZZ. I think what would make more sense for your need is a frequency rule. |
Beta Was this translation helpful? Give feedback.
Cardinality is the measure of unique values for a given field. So the only way it would trigger is if you had 10 different log levels show up in a 4 hour timeframe. Ex: INFO, DEBUG, ERROR, WARN, TRACE, FATAL, VERBOSE, XXX, YYY, ZZZ.
I think what would make more sense for your need is a frequency rule.