fixed erroneous usage of rate() function on gauges (#270)

Co-authored-by: Dressler Armon, B2B-PAP-HLT-DO-ENG <armon.dressler@swisscom.com>
This commit is contained in:
armondressler 2022-01-16 03:24:36 +01:00 committed by GitHub
parent 37722256d5
commit 038e46743d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -494,12 +494,12 @@ groups:
severity: critical
- name: MySQL too many connections (> 80%)
description: 'More than 80% of MySQL connections are in use on {{ $labels.instance }}'
query: 'avg by (instance) (rate(mysql_global_status_threads_connected[1m])) / avg by (instance) (mysql_global_variables_max_connections) * 100 > 80'
query: 'max_over_time(mysql_global_status_threads_connected[1m]) / mysql_global_variables_max_connections * 100 > 80'
severity: warning
for: 2m
- name: MySQL high threads running
description: 'More than 60% of MySQL connections are in running state on {{ $labels.instance }}'
query: 'avg by (instance) (rate(mysql_global_status_threads_running[1m])) / avg by (instance) (mysql_global_variables_max_connections) * 100 > 60'
query: 'max_over_time(mysql_global_status_threads_running[1m]) / mysql_global_variables_max_connections * 100 > 60'
severity: warning
for: 2m
- name: MySQL Slave IO thread not running