mirror of
https://github.com/ceph/ceph
synced 2025-03-09 09:48:09 +00:00
PG: add a config option to enable (by default) recovery below min_size
This may be useful at some point. Signed-off-by: Samuel Just <sjust@redhat.com>
This commit is contained in:
parent
1fa74bee3f
commit
1d0d3dc8db
@ -505,6 +505,10 @@ OPTION(osd_erasure_code_plugins, OPT_STR,
|
||||
" isa"
|
||||
#endif
|
||||
) // list of erasure code plugins
|
||||
|
||||
// Allows the "peered" state for recovery and backfill below min_size
|
||||
OPTION(osd_allow_recovery_below_min_size, OPT_BOOL, true)
|
||||
|
||||
OPTION(osd_pool_default_flags, OPT_INT, 0) // default flags for new pools
|
||||
OPTION(osd_pool_default_flag_hashpspool, OPT_BOOL, true) // use new pg hashing to prevent pool/pg overlap
|
||||
OPTION(osd_pool_default_flag_nodelete, OPT_BOOL, false) // pool can't be deleted
|
||||
|
@ -1312,7 +1312,8 @@ bool PG::choose_acting(pg_shard_t &auth_log_shard_id)
|
||||
// Otherwise, we will go "peered", but not "active"
|
||||
if (num_want_acting < pool.info.min_size &&
|
||||
(pool.info.ec_pool() ||
|
||||
!(get_min_peer_features() & CEPH_FEATURE_OSD_MIN_SIZE_RECOVERY))) {
|
||||
(!(get_min_peer_features() & CEPH_FEATURE_OSD_MIN_SIZE_RECOVERY)) ||
|
||||
!cct->_conf->osd_allow_recovery_below_min_size)) {
|
||||
want_acting.clear();
|
||||
dout(10) << "choose_acting failed, below min size" << dendl;
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user