infra/k8s/operators/kube-prometheus/node-exporter-rules-patches.yaml

37 lines
2.1 KiB
YAML

# NodeFilesystemFilesFillingUp/NodeFilesystemAlmostOutOfFiles: ignore rclone filesystems
- op: replace
path: /spec/groups/0/rules/4/expr # NodeFilesystemFilesFillingUp warning
value: |
(
node_filesystem_files_free{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} / node_filesystem_files{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} * 100 < 40
and
predict_linear(node_filesystem_files_free{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""}[6h], 24*60*60) < 0
and
node_filesystem_readonly{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} == 0
)
- op: replace
path: /spec/groups/0/rules/5/expr # NodeFilesystemFilesFillingUp critical
value: |
(
node_filesystem_files_free{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} / node_filesystem_files{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} * 100 < 20
and
predict_linear(node_filesystem_files_free{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""}[6h], 4*60*60) < 0
and
node_filesystem_readonly{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} == 0
)
- op: replace
path: /spec/groups/0/rules/6/expr # NodeFilesystemAlmostOutOfFiles warning
value: |
(
node_filesystem_files_free{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} / node_filesystem_files{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} * 100 < 5
and
node_filesystem_readonly{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} == 0
)
- op: replace
path: /spec/groups/0/rules/7/expr # NodeFilesystemAlmostOutOfFiles critical
value: |
(
node_filesystem_files_free{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} / node_filesystem_files{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} * 100 < 3
and
node_filesystem_readonly{job="node-exporter",fstype!="",fstype!="fuse.rclone",mountpoint!=""} == 0
)