Open wxiaoke opened 2 years ago
WDYT @mikechengwei
@wxiaoke Does https://docs.pingcap.com/tidb-in-kubernetes/dev/monitor-a-tidb-cluster#use-a-customized-configuration-file this work for you?
NO,The following step is working. 使用 pvc 持久化步骤更新:
cat pvc1.yaml
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: pro-rules
namespace: tidb-cluster
spec:
storageClassName: local-storage
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
additionalVolumes:
- name: pro-rules
persistentVolumeClaim:
claimName: pro-rules
prometheus:
additionalVolumeMounts:
- name: pro-rules
mountPath: "/prometheus-rules/rules/"
At present, the persistent storage of tm is the data directory in the prometheus container. If the rules of prometheus are manually changed, persistent storage cannot be performed. It is recommended to persist this directory as well.
Whether to consider adding prometheus-rules to the data directory