File tree Expand file tree Collapse file tree 3 files changed +45
-0
lines changed
monitoring/kube-prometheus-stack/chart/rules
storage/longhorn/chart/templates Expand file tree Collapse file tree 3 files changed +45
-0
lines changed Original file line number Diff line number Diff line change
1
+ apiVersion : k8s.mariadb.com/v1alpha1
2
+ kind : Backup
3
+ metadata :
4
+ name : mariabackup
5
+ spec :
6
+ mariaDbRef :
7
+ name : mariadb
8
+ schedule :
9
+ cron : " 0 */2 * * *"
10
+ maxRetention : 72h
11
+
12
+ storage :
13
+ persistentVolumeClaim :
14
+ storageClassName : longhorn-single-hourly
15
+
16
+ resources :
17
+ requests :
18
+ storage : 15Gi
19
+ accessModes :
20
+ - ReadWriteOnce
Original file line number Diff line number Diff line change @@ -103,6 +103,18 @@ spec:
103
103
summary : ArgoCD service not synced (instance {{ $labels.instance }})
104
104
- name : db
105
105
rules :
106
+ - alert : GaleraClusterSize
107
+ expr : |
108
+ (
109
+ min(mysql_global_status_wsrep_cluster_size{job="mariadb-metrics", namespace="databases"})
110
+ -
111
+ sum(kube_statefulset_replicas{namespace="databases", statefulset="mariadb"})
112
+ ) != 0
113
+ for : 5m
114
+ labels :
115
+ severity : critical
116
+ annotations :
117
+ summary : Galera cluster size is not equal to the number of replicase
106
118
- alert : MysqlDown
107
119
expr : mysql_up{service!~"srep.*"} == 0
108
120
for : 0m
Original file line number Diff line number Diff line change
1
+ apiVersion : storage.k8s.io/v1
2
+ kind : StorageClass
3
+ metadata :
4
+ name : longhorn-single-hourly
5
+ provisioner : driver.longhorn.io
6
+ allowVolumeExpansion : true
7
+ reclaimPolicy : Delete
8
+ volumeBindingMode : Immediate
9
+ parameters :
10
+ numberOfReplicas : " 1"
11
+ recurringJobSelector :
12
+ - name : hourly
13
+ isGroup : true
You can’t perform that action at this time.
0 commit comments