itamae/cookbooks/prometheus/files/etc/prometheus.d/alerts/filestat.yml

21 lines
605 B
YAML
Raw Normal View History

2020-09-27 05:03:13 +00:00
groups:
- name: filestat
rules:
- alert: RebootRequired
expr: file_glob_match_number{pattern="/var/run/reboot-required"} > 0
for: 24h
labels:
severity: warning
annotations:
summary: "Instance {{ $labels.instance }} requires rebooting."
description: "{{ $labels.instance }} requires rebooting."
2020-10-24 04:06:54 +00:00
- alert: apt-mirror
expr: time() - file_stat_modif_time_seconds{path="/var/spool/apt-mirror/updated"} > 87000
for: 12h
labels:
severity: error
annotations:
summary: "apt-mirror is not updated."
description: "apt-mirror is not updated."