Enable bluestore by default
For Ceph Lumimous (12.2.0) or later enable Bluestore block device format as the default for Ceph OSD's. Bluestore can be disabled by setting the bluestore config option to False. For older releases, Bluestore cannot be enabled as its not supported - setting the config option will have no effect. Change-Id: I5ca657b9c4da055c4e0ff12e8b91b39d0964be8c
This commit is contained in:
parent
488f7dffef
commit
8875a7a685
|
@ -120,13 +120,10 @@ options:
|
|||
Only supported with ceph >= 0.48.3.
|
||||
bluestore:
|
||||
type: boolean
|
||||
default: false
|
||||
default: True
|
||||
description: |
|
||||
Use experimental bluestore storage format for OSD devices; only supported
|
||||
in Ceph Jewel (10.2.0) or later.
|
||||
.
|
||||
Note that despite bluestore being the default for Ceph Luminous, if this
|
||||
option is False, OSDs will still use filestore.
|
||||
Enable bluestore storage format for OSD devices; Only applies for Ceph
|
||||
Luminous or later.
|
||||
osd-encrypt:
|
||||
type: boolean
|
||||
default: False
|
||||
|
|
|
@ -220,6 +220,16 @@ def use_vaultlocker():
|
|||
return False
|
||||
|
||||
|
||||
def use_bluestore():
|
||||
"""Determine whether bluestore should be used for OSD's
|
||||
|
||||
:returns: whether bluestore disk format should be used
|
||||
:rtype: bool"""
|
||||
if cmp_pkgrevno('ceph', '10.2.0') < 0:
|
||||
return False
|
||||
return config('bluestore')
|
||||
|
||||
|
||||
def install_apparmor_profile():
|
||||
"""
|
||||
Install ceph apparmor profiles and configure
|
||||
|
@ -336,7 +346,7 @@ def get_ceph_context(upgrading=False):
|
|||
'dio': str(config('use-direct-io')).lower(),
|
||||
'short_object_len': use_short_objects(),
|
||||
'upgrade_in_progress': upgrading,
|
||||
'bluestore': config('bluestore'),
|
||||
'bluestore': use_bluestore(),
|
||||
'bluestore_experimental': cmp_pkgrevno('ceph', '12.1.0') < 0,
|
||||
'bluestore_block_wal_size': config('bluestore-block-wal-size'),
|
||||
'bluestore_block_db_size': config('bluestore-block-db-size'),
|
||||
|
@ -468,12 +478,13 @@ def prepare_disks_and_activate():
|
|||
if ceph.is_bootstrapped():
|
||||
log('ceph bootstrapped, rescanning disks')
|
||||
emit_cephconf()
|
||||
bluestore = use_bluestore()
|
||||
for dev in get_devices():
|
||||
ceph.osdize(dev, config('osd-format'),
|
||||
osd_journal,
|
||||
config('ignore-device-errors'),
|
||||
config('osd-encrypt'),
|
||||
config('bluestore'),
|
||||
bluestore,
|
||||
config('osd-encrypt-keymanager'))
|
||||
# Make it fast!
|
||||
if config('autotune'):
|
||||
|
|
|
@ -398,8 +398,6 @@ class CephOsdBasicDeployment(OpenStackAmuletDeployment):
|
|||
},
|
||||
'osd': {
|
||||
'keyring': '/var/lib/ceph/osd/$cluster-$id/keyring',
|
||||
'osd journal size': '1024',
|
||||
'filestore xattr use omap': 'true'
|
||||
},
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue