From: Rongqi Sun Date: Wed, 1 Mar 2023 08:15:26 +0000 (+0800) Subject: cephadm: eliminate duplication of [global] section when applying set-extra-ceph-conf X-Git-Tag: v19.0.0~1602^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ece7ccccc915392bced60c07703eb82142874516;p=ceph.git cephadm: eliminate duplication of [global] section when applying set-extra-ceph-conf Signed-off-by: Rongqi Sun --- diff --git a/src/pybind/mgr/cephadm/module.py b/src/pybind/mgr/cephadm/module.py index 42bb65a7279d..b567871bd21f 100644 --- a/src/pybind/mgr/cephadm/module.py +++ b/src/pybind/mgr/cephadm/module.py @@ -1905,7 +1905,7 @@ Then run the following: }) extra = self.extra_ceph_conf().conf if extra: - config += '\n\n' + extra.strip() + '\n' + config += extra.strip().replace('[global]','') + '\n' return config def _invalidate_daemons_and_kick_serve(self, filter_host: Optional[str] = None) -> None: