prometheus: fix quanta temp alert queries

This commit is contained in:
jeltz 2023-11-04 14:02:06 +01:00
parent 68f36ae048
commit 9eb5793b38
Signed by: jeltz
GPG key ID: 800882B66C0C3326

View file

@ -58,15 +58,16 @@ prometheus__rules_quanta:
- alert: QuantaMissingIntakeTemp - alert: QuantaMissingIntakeTemp
expr: expr:
count by (instance) ( count by (instance) (
snAgentTempValue unless snAgentTempValue
) - count by (instance) (
snAgentTempValue{snAgentTempSensorDescr=~".*Intake.*"} snAgentTempValue{snAgentTempSensorDescr=~".*Intake.*"}
) > 0 ) == 0
for: 0m for: 0m
labels: labels:
severity: critical severity: critical
- alert: QuantaIntakeTemp - alert: QuantaIntakeTemp
expr: expr:
0.5 * snAgentTempValue{snAgentTempSensorDesc=~".*Intake.*"} > 45 0.5 * snAgentTempValue{snAgentTempSensorDescr=~".*Intake.*"} > 45
for: 10m for: 10m
keep_firing_for: 30m keep_firing_for: 30m
labels: labels:
@ -76,7 +77,7 @@ prometheus__rules_quanta:
Description: !unsafe "{{ $labels.snAgentTempSensorDescr }}" Description: !unsafe "{{ $labels.snAgentTempSensorDescr }}"
- alert: QuantaIntakeTemp - alert: QuantaIntakeTemp
expr: expr:
0.5 * snAgentTempValue{snAgentTempSensorDesc=~".*Intake.*"} > 60 0.5 * snAgentTempValue{snAgentTempSensorDescr=~".*Intake.*"} > 60
for: 10m for: 10m
keep_firing_for: 30m keep_firing_for: 30m
labels: labels: