Mohammed Naser | b8eccd2 | 2023-02-10 05:55:56 +0000 | [diff] [blame] | 1 | groups: |
| 2 | - name: persistent-volume-alert.rules |
| 3 | rules: |
| 4 | - alert: PersistentVolumeUsageNearFull |
| 5 | annotations: |
| 6 | description: PVC {{ $labels.persistentvolumeclaim }} utilization has crossed 75%. Free up some space or expand the PVC. |
| 7 | message: PVC {{ $labels.persistentvolumeclaim }} is nearing full. Data deletion or PVC expansion is required. |
| 8 | severity_level: warning |
| 9 | storage_type: ceph |
| 10 | expr: | |
| 11 | (kubelet_volume_stats_used_bytes * on (namespace,persistentvolumeclaim) group_left(storageclass, provisioner) (kube_persistentvolumeclaim_info * on (storageclass) group_left(provisioner) kube_storageclass_info {provisioner=~"(.*rbd.csi.ceph.com)|(.*cephfs.csi.ceph.com)"})) / (kubelet_volume_stats_capacity_bytes * on (namespace,persistentvolumeclaim) group_left(storageclass, provisioner) (kube_persistentvolumeclaim_info * on (storageclass) group_left(provisioner) kube_storageclass_info {provisioner=~"(.*rbd.csi.ceph.com)|(.*cephfs.csi.ceph.com)"})) > 0.75 |
| 12 | for: 5s |
| 13 | labels: |
| 14 | severity: warning |
| 15 | - alert: PersistentVolumeUsageCritical |
| 16 | annotations: |
| 17 | description: PVC {{ $labels.persistentvolumeclaim }} utilization has crossed 85%. Free up some space or expand the PVC immediately. |
| 18 | message: PVC {{ $labels.persistentvolumeclaim }} is critically full. Data deletion or PVC expansion is required. |
| 19 | severity_level: error |
| 20 | storage_type: ceph |
| 21 | expr: | |
| 22 | (kubelet_volume_stats_used_bytes * on (namespace,persistentvolumeclaim) group_left(storageclass, provisioner) (kube_persistentvolumeclaim_info * on (storageclass) group_left(provisioner) kube_storageclass_info {provisioner=~"(.*rbd.csi.ceph.com)|(.*cephfs.csi.ceph.com)"})) / (kubelet_volume_stats_capacity_bytes * on (namespace,persistentvolumeclaim) group_left(storageclass, provisioner) (kube_persistentvolumeclaim_info * on (storageclass) group_left(provisioner) kube_storageclass_info {provisioner=~"(.*rbd.csi.ceph.com)|(.*cephfs.csi.ceph.com)"})) > 0.85 |
| 23 | for: 5s |
| 24 | labels: |
| 25 | severity: critical |