From: Alfredo Deza Date: Wed, 1 Aug 2018 21:01:31 +0000 (-0400) Subject: ceph-volume lvm.activate conditional mon-config on prime-osd-dir X-Git-Tag: v13.2.2~115^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F23400%2Fhead;p=ceph.git ceph-volume lvm.activate conditional mon-config on prime-osd-dir The --no-mon-config should only be done in Mimic releaes and later Signed-off-by: Alfredo Deza (cherry picked from commit 020d6b1e5555e4547e8a0a19bd29eea89e1b7a31) --- diff --git a/src/ceph-volume/ceph_volume/devices/lvm/activate.py b/src/ceph-volume/ceph_volume/devices/lvm/activate.py index adebe2f4fa91a..cedb62caac41c 100644 --- a/src/ceph-volume/ceph_volume/devices/lvm/activate.py +++ b/src/ceph-volume/ceph_volume/devices/lvm/activate.py @@ -3,7 +3,7 @@ import argparse import logging import os from textwrap import dedent -from ceph_volume import process, conf, decorators, terminal +from ceph_volume import process, conf, decorators, terminal, __release__ from ceph_volume.util import system, disk from ceph_volume.util import prepare as prepare_utils from ceph_volume.util import encryption as encryption_utils @@ -148,10 +148,16 @@ def activate_bluestore(lvs, no_systemd=False): wal_device_path = get_osd_device_path(osd_lv, lvs, 'wal', dmcrypt_secret=dmcrypt_secret) # Once symlinks are removed, the osd dir can be 'primed again. - process.run([ + prime_command = [ 'ceph-bluestore-tool', '--cluster=%s' % conf.cluster, 'prime-osd-dir', '--dev', osd_lv_path, - '--path', osd_path, '--no-mon-config']) + '--path', osd_path] + + if __release__ != "luminous": + # mon-config changes are not available in Luminous + prime_command.append('--no-mon-config') + + process.run(prime_command) # always re-do the symlink regardless if it exists, so that the block, # block.wal, and block.db devices that may have changed can be mapped # correctly every time