# Question on Error Rate Alert: am I doing it right?

**URL:** <https://discuss.prometheus.io/t/question-on-error-rate-alert-am-i-doing-it-right/1296>\
**Category:** General Help/Support\
**Created:** [November 13, 2022, 10:07am UTC](https://discuss.prometheus.io/t/question-on-error-rate-alert-am-i-doing-it-right/1296 "2022-11-13T10:07:59Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![idioma](https://avatars.discourse-cdn.com/v4/letter/i/dbc845/32.png) [@idioma](https://discuss.prometheus.io/u/idioma)\
**Post date:** [November 13, 2022, 10:07am UTC](https://discuss.prometheus.io/t/question-on-error-rate-alert-am-i-doing-it-right/1296/1 "2022-11-13T10:07:59Z")

</div>

Hi,  
I have the following alert in Prometheus whose goal is to be triggered when the number of errors out of the total number of requests is higher than 5 %:

`sum(increase(errorMetric{service_name="someservice"}[5m])) / sum(increase(http_requests_count{service_name="someservice", path="/some/path"}[5m])) > 0.05`

Is this the correct way to represent the intention behind this alert?  
I have an overall idea of the traffic and it can range between 100 requests per hour over 24h interval. How valuable is having the interval set for 5m? Shall this range over a longer period of time, e.g. 1h. This alert goes off and it does not really inform us of a problem. What is your view?

Thank you

---

<div class="post-metadata">

**Author:** ![idioma](https://avatars.discourse-cdn.com/v4/letter/i/dbc845/32.png) [@idioma](https://discuss.prometheus.io/u/idioma)\
**Post date:** [November 14, 2022, 12:50pm UTC](https://discuss.prometheus.io/t/question-on-error-rate-alert-am-i-doing-it-right/1296/2 "2022-11-14T12:50:31Z")

</div>

I would be also interested to know whether `rate` is better than `increase`. Could you please provide any help? Thank you
