From f90d5d8b4c01b1f7e398bbdc59adcfc00d12ed19 Mon Sep 17 00:00:00 2001 From: Seena Fallah Date: Mon, 22 May 2023 22:44:46 +0200 Subject: [PATCH] ceph-config: drop osd_memory_target from ceph_conf_overrides As it's always being set in ceph.conf template, it leads to having duplicated osd_memory_target keys in rendered ceph conf while defining one in ceph_conf_overrides. Signed-off-by: Seena Fallah --- roles/ceph-config/tasks/main.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/roles/ceph-config/tasks/main.yml b/roles/ceph-config/tasks/main.yml index cd25b0a20..1e31f86a9 100644 --- a/roles/ceph-config/tasks/main.yml +++ b/roles/ceph-config/tasks/main.yml @@ -104,6 +104,13 @@ - "{{ ceph_conf_overrides.get('osd', {}).get('osd_memory_target', '') }}" when: item + - name: drop osd_memory_target from conf override + set_fact: + ceph_conf_overrides: "{{ ceph_conf_overrides | combine({'osd': {item: omit}}, recursive=true) }}" + loop: + - osd memory target + - osd_memory_target + - name: set_fact _osd_memory_target set_fact: _osd_memory_target: "{{ ((ansible_facts['memtotal_mb'] * 1048576 * safety_factor | float) / num_osds | float) | int }}" -- 2.39.5