From 865c7d08728d4aa76128dfcce6fa0bf07696325c Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Sat, 9 Dec 2023 23:51:29 -0500 Subject: [PATCH] Add Ceph Prometheus configurations (0.9.84) --- roles/pvc/tasks/ceph/main.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/roles/pvc/tasks/ceph/main.yml b/roles/pvc/tasks/ceph/main.yml index 21b0b93..d5d2b6f 100644 --- a/roles/pvc/tasks/ceph/main.yml +++ b/roles/pvc/tasks/ceph/main.yml @@ -116,6 +116,21 @@ run_once: yes ignore_errors: yes +- name: set Prometheus metric exporter enabled + command: ceph mgr module enable prometheus + run_once: yes + ignore_errors: yes + +- name: enable Prometheus metrics on all pools + command: ceph config set mgr mgr/prometheus/rbd_stats_pools "*" + run_once: yes + ignore_errors: yes + +- name: explicitly enable Prometheus performance counters + command: ceph config set mgr mgr/prometheus/exclude_perf_counters false + run_once: yes + ignore_errors: yes + - name: create mgr auth keyring command: ceph auth get-or-create mgr.{{ ansible_hostname }} mon 'allow profile mgr' osd 'allow *' mds 'allow *' --out-file /var/lib/ceph/mgr/ceph-{{ ansible_hostname }}/keyring become_user: ceph