mirror of
https://github.com/samber/awesome-prometheus-alerts.git
synced 2026-06-25 02:46:59 +08:00
removed avg grouping where possible
This commit is contained in:
parent
4860250360
commit
79b5ad3b5d
1 changed files with 6 additions and 6 deletions
|
|
@ -312,7 +312,7 @@ groups:
|
||||||
rules:
|
rules:
|
||||||
- name: MySQL down
|
- name: MySQL down
|
||||||
description: MySQL instance is down on {{ $labels.instance }}
|
description: MySQL instance is down on {{ $labels.instance }}
|
||||||
query: 'avg by (instance) (mysql_up) == 0'
|
query: 'mysql_up == 0'
|
||||||
severity: error
|
severity: error
|
||||||
- name: MySQL too many connections
|
- name: MySQL too many connections
|
||||||
description: 'More than 80% of MySQL connections are in use on {{ $labels.instance }}'
|
description: 'More than 80% of MySQL connections are in use on {{ $labels.instance }}'
|
||||||
|
|
@ -324,15 +324,15 @@ groups:
|
||||||
severity: warning
|
severity: warning
|
||||||
- name: MySQL Slave IO thread not running on {{ $instance.instance }}
|
- name: MySQL Slave IO thread not running on {{ $instance.instance }}
|
||||||
description: 'MySQL Slave IO thread not running on {{ $labels.instance }}'
|
description: 'MySQL Slave IO thread not running on {{ $labels.instance }}'
|
||||||
query: 'avg by(instance) (mysql_slave_status_master_server_id) > 0 and avg by (instance) (mysql_slave_status_slave_io_running) == 0'
|
query: 'mysql_slave_status_master_server_id > 0 and mysql_slave_status_slave_io_running == 0'
|
||||||
severity: error
|
severity: error
|
||||||
- name: MySQL Slave SQL thread not running on {{ $instance.instance }}
|
- name: MySQL Slave SQL thread not running on {{ $instance.instance }}
|
||||||
description: 'MySQL Slave SQL thread not running on {{ $labels.instance }}'
|
description: 'MySQL Slave SQL thread not running on {{ $labels.instance }}'
|
||||||
query: 'avg by(instance) (mysql_slave_status_master_server_id) > 0 and avg by (instance) (mysql_slave_status_slave_sql_running) == 0'
|
query: 'mysql_slave_status_master_server_id > 0 and mysql_slave_status_slave_sql_running == 0'
|
||||||
severity: error
|
severity: error
|
||||||
- name: MySQL Slave replication lag {{ $instance.instance }}
|
- name: MySQL Slave replication lag {{ $instance.instance }}
|
||||||
description: 'MysqL replication lag on {{ $labels.instance }}'
|
description: 'MysqL replication lag on {{ $labels.instance }}'
|
||||||
query: 'avg by(instance) (mysql_slave_status_master_server_id) > 0 and (avg by (instance) (max_over_time(mysql_slave_status_seconds_behind_master[1m])) - avg by (instance) (mysql_slave_status_sql_delay)) > 300'
|
query: 'mysql_slave_status_master_server_id > 0 and (mysql_slave_status_seconds_behind_master - mysql_slave_status_sql_delay) > 300'
|
||||||
severity: warning
|
severity: warning
|
||||||
- name: MySQL slow queries
|
- name: MySQL slow queries
|
||||||
description: MySQL server is having some slow queries.
|
description: MySQL server is having some slow queries.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue