In my setup, Prometheus is monitoring multiple nodes simultaneously, say, x,y z.
I want to raise alerts, once cpu utilization exceeds "a" value for each of the nodes.
Below is the alert rule.
alert: cpu_utilization
expr: 100 - (avg by(instance) (irate(node_cpu_seconds_total{job="--",mode="idle"}[5m])) * 100) > a
labels:
severity: critical
annotations:
summary: CPU utilization has crossed a%
QUERY:
1) How can I use the same rule for multiple nodes/jobs? Is there any way to update job names dynamically? As I want to avoid multiple alert rules for each job.
Thanks,