Adapt job class rules

This commit is contained in:
Jan Eitzinger 2025-05-28 14:32:49 +02:00
parent bdffe73f59
commit 4a5fd96b32
2 changed files with 6 additions and 7 deletions

View File

@ -1,7 +1,6 @@
{ {
"name": "Excessive CPU load", "name": "Excessive CPU load",
"tag": "excessiveload", "tag": "excessiveload",
"comment": "Assumptions: all nodes have the same number of cores.",
"parameters": [ "parameters": [
"excessivecpuload_threshold_factor", "excessivecpuload_threshold_factor",
"job_min_duration_seconds", "job_min_duration_seconds",
@ -19,9 +18,9 @@
}, },
{ {
"name": "load_perc", "name": "load_perc",
"expr": "cpu_load.avg / load_threshold" "expr": "cpu_load.avg / cpu_load.limits.peak"
} }
], ],
"rule": "cpu_load > load_threshold", "rule": "cpu_load.avg > cpu_load.limits.peak",
"hint": "This job was detected as excessiveload because the average cpu load {{.cpu_load}} falls above the threshold {{.load_threshold}}." "hint": "This job was detected as excessiveload because the average cpu load {{.cpu_load.avg}} falls above the threshold {{.cpu_load.limits.peak}}."
} }

View File

@ -18,9 +18,9 @@
}, },
{ {
"name": "load_perc", "name": "load_perc",
"expr": "1.0 - (cpu_load / load_threshold)" "expr": "1.0 - (cpu_load.avg / cpu_load.limits.peak)"
} }
], ],
"rule": "cpu_load.avg < load_threshold", "rule": "cpu_load.avg < cpu_load.limits.caution",
"hint": "This job was detected as lowload because the average cpu load {{.cpu_load}} falls below the threshold {{.load_threshold}}." "hint": "This job was detected as lowload because the average cpu load {{.cpu_load}} falls below the threshold {{.cpu_load.limits.caution}}."
} }