Files
RPi5-PTP-server/exporters/examples/alerts.yml

52 lines
1.5 KiB
YAML
Raw Normal View History

groups:
- name: ptp
rules:
- alert: PTPExporterDown
expr: up{job=~"ptp-linux|ptp-nexus"} == 0
for: 2m
labels:
severity: warning
annotations:
summary: "PTP exporter is unreachable on {{ $labels.instance }}"
- alert: LinuxPTPScrapeFailed
expr: ptp_exporter_scrape_success{stage!="ok"} == 0
for: 2m
labels:
severity: warning
annotations:
summary: "linuxptp PMC scrape failed on {{ $labels.instance }}"
- alert: PTPGrandmasterMissing
expr: ptp_gm_present == 0
for: 30s
labels:
severity: critical
annotations:
summary: "PTP grandmaster is not present on {{ $labels.instance }}"
- alert: NexusPTPUnlocked
expr: ptp_nexus_clock_locked == 0
for: 30s
labels:
severity: critical
annotations:
summary: "Nexus PTP clock is not locked"
# Start conservatively and tighten this after observing normal behavior.
- alert: PTPMasterOffsetHigh
expr: abs(ptp_master_offset_nanoseconds) > 1000
for: 5m
labels:
severity: warning
annotations:
summary: "PTP offset exceeds 1 us on {{ $labels.instance }}"
- alert: NexusPTPMasterOffsetHigh
expr: abs(ptp_nexus_offset_from_master_nanoseconds) > 1000
for: 5m
labels:
severity: warning
annotations:
summary: "Nexus PTP offset exceeds 1 us"