Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alert user if ceph metadata server is consuming cpu at threshold point. #2307

Merged
merged 1 commit into from
Dec 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions metrics/deploy/prometheus-ocs-rules.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -286,3 +286,16 @@ spec:
for: 15m
labels:
severity: warning
- alert: MDSCPUUsageHigh
annotations:
description: |-
Ceph metadata server pod ({{ $labels.pod }}) has high cpu usage.
Please consider increasing the number of active metadata servers,
it can be done by increasing the number of activeMetadataServers parameter in the StorageCluster CR.
message: Ceph metadata server pod ({{ $labels.pod }}) has high cpu usage
severity_level: warning
expr: |
pod:container_cpu_usage:sum{pod=~"rook-ceph-mds.*"}/ on(pod) kube_pod_resource_limit{resource='cpu',pod=~"rook-ceph-mds.*"} > 0.67
for: 6h
labels:
severity: warning
16 changes: 16 additions & 0 deletions metrics/mixin/alerts/perf.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,22 @@
severity_level: 'warning',
},
},

{
alert: 'MDSCPUUsageHigh',
expr: |||
pod:container_cpu_usage:sum{%(mdsSelector)s}/ on(pod) kube_pod_resource_limit{resource='cpu',%(mdsSelector)s} > 0.67
umangachapagain marked this conversation as resolved.
Show resolved Hide resolved
||| % $._config,
'for': $._config.mds_cpu_usage_high_threshold_duration,
labels: {
severity: 'warning',
},
annotations: {
message: 'Ceph metadata server pod ({{ $labels.pod }}) has high cpu usage',
description: 'Ceph metadata server pod ({{ $labels.pod }}) has high cpu usage.\nPlease consider increasing the number of active metadata servers,\nit can be done by increasing the number of activeMetadataServers parameter in the StorageCluster CR.',
severity_level: 'warning',
manishym marked this conversation as resolved.
Show resolved Hide resolved
},
},
],
},
],
Expand Down
2 changes: 2 additions & 0 deletions metrics/mixin/config.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
ocsStorageClusterKMSConnectionAlert: '5s',
mdsCacheUsageAlertTime: '5m',
osdCPULoadHighAlertTime: '15m',
mdsSelector: 'pod=~"rook-ceph-mds.*"',
mds_cpu_usage_high_threshold_duration: '6h',
manishym marked this conversation as resolved.
Show resolved Hide resolved

// Constants
objectStorageType: 'RGW',
Expand Down