common: add option to disable filestore sharded object check

Signed-off-by: Samuel Just <sam.just@inktank.com>
This commit is contained in:
Samuel Just 2013-12-05 13:57:44 -08:00
parent 1b5992b0f0
commit 1b0335ed66
2 changed files with 4 additions and 1 deletions

View File

@ -543,6 +543,8 @@ OPTION(osd_objectstore, OPT_STR, "filestore") // ObjectStore backend type
// Set to true for testing. Users should NOT set this.
OPTION(osd_debug_override_acting_compat, OPT_BOOL, false)
OPTION(filestore_debug_disable_sharded_check, OPT_BOOL, false)
/// filestore wb throttle limits
OPTION(filestore_wbthrottle_enable, OPT_BOOL, true)
OPTION(filestore_wbthrottle_btrfs_bytes_start_flusher, OPT_U64, 41943040)

View File

@ -1010,7 +1010,8 @@ void FileStore::set_allow_sharded_objects()
bool FileStore::get_allow_sharded_objects()
{
return superblock.compat_features.incompat.contains(CEPH_FS_FEATURE_INCOMPAT_SHARDS);
return g_conf->filestore_debug_disable_sharded_check ||
superblock.compat_features.incompat.contains(CEPH_FS_FEATURE_INCOMPAT_SHARDS);
}
int FileStore::update_version_stamp()