Skip to content

Commit 158d13e

Browse files
committed
optimization: increase alerts firing to be 30s instead of 10s
1 parent 3a9cb68 commit 158d13e

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

playbooks/roles/prometheus/templates/alert_rules.yml.j2

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ groups:
55
- alert: HighCPUUsage
66
expr: |
77
100 - (avg by (instance) (irate(node_cpu_seconds_total{mode="idle"}[1m])) * 100) > {{ cpu_usage_threshold | default(80) }}
8-
for: 10s # this need to be changed for production alerts, its 10s for test purposes only
8+
for: 30s # this need to be changed for production alerts, its 10s for test purposes only
99
labels:
1010
severity: warning
1111
annotations:
@@ -16,7 +16,7 @@ groups:
1616
- alert: HighMemoryUsage
1717
expr: |
1818
(1 - (node_memory_MemAvailable_bytes / node_memory_MemTotal_bytes)) * 100 > {{ memory_usage_threshold | default(80) }}
19-
for: 10s # this need to be changed for production alerts, its 10s for test purposes only
19+
for: 30s # this need to be changed for production alerts, its 10s for test purposes only
2020
labels:
2121
severity: warning
2222
annotations:
@@ -27,7 +27,7 @@ groups:
2727
- alert: DiskSpaceLow
2828
expr: |
2929
(node_filesystem_avail_bytes / node_filesystem_size_bytes) * 100 < {{ disk_space_threshold | default(20) }}
30-
for: 10s # this need to be changed for production alerts, its 10s for test purposes only
30+
for: 30s # this need to be changed for production alerts, its 10s for test purposes only
3131
labels:
3232
severity: warning
3333
annotations:
@@ -38,7 +38,7 @@ groups:
3838
- alert: HighDiskIOUsage
3939
expr: |
4040
(irate(node_disk_io_time_seconds_total[1m]) * 100) > {{ disk_io_threshold | default(40) }}
41-
for: 10s # this need to be changed for production alerts, its 10s for test purposes only
41+
for: 30s # this need to be changed for production alerts, its 10s for test purposes only
4242
labels:
4343
severity: critical
4444
annotations:
@@ -59,7 +59,7 @@ groups:
5959
- alert: DiskInodesLow
6060
expr: |
6161
(node_filesystem_files_free / node_filesystem_files) * 100 < {{ inode_threshold | default(10) }}
62-
for: 10s # this need to be changed for production alerts, its 10s for test purposes only
62+
for: 30s # this need to be changed for production alerts, its 10s for test purposes only
6363
labels:
6464
severity: warning
6565
annotations:
@@ -71,7 +71,7 @@ groups:
7171
- alert: NodeExporterDown
7272
expr: |
7373
up{job="node_exporter"} == 0
74-
for: 10s # this need to be changed for production alerts, its 10s for test purposes only
74+
for: 30s # this need to be changed for production alerts, its 10s for test purposes only
7575
labels:
7676
severity: critical
7777
annotations:
@@ -82,7 +82,7 @@ groups:
8282
- alert: GrafanaDown
8383
expr: |
8484
up{instance="grafana"} == 0
85-
for: 10s # this need to be changed for production alerts, its 10s for test purposes only
85+
for: 30s # this need to be changed for production alerts, its 10s for test purposes only
8686
labels:
8787
severity: critical
8888
annotations:

0 commit comments

Comments
 (0)