From: Somnath Roy Date: Tue, 10 Jun 2014 23:02:52 +0000 (-0700) Subject: ShardedTP: The config option changed X-Git-Tag: v0.83~110^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=2a5d83d2d56dbee7ddbdb434a178fe85f672f600;p=ceph.git ShardedTP: The config option changed The config option for sharded threadpool is changed to osd_op_num_threads_per_shard instead of osd_op_num_sharded_pool_threads. Along with osd_op_num_shards this will be much more user friendly while configuring the number of op threads for the osd. Signed-off-by: Somnath Roy --- diff --git a/src/common/config_opts.h b/src/common/config_opts.h index 8d28e8a9a42d..d3e912c9374f 100644 --- a/src/common/config_opts.h +++ b/src/common/config_opts.h @@ -466,7 +466,7 @@ OPTION(osd_op_pq_min_cost, OPT_U64, 65536) OPTION(osd_disk_threads, OPT_INT, 1) OPTION(osd_recovery_threads, OPT_INT, 1) OPTION(osd_recover_clone_overlap, OPT_BOOL, true) // preserve clone_overlap during recovery/migration -OPTION(osd_op_num_sharded_pool_threads, OPT_INT, 10) +OPTION(osd_op_num_threads_per_shard, OPT_INT, 2) OPTION(osd_op_num_shards, OPT_INT, 5) // Only use clone_overlap for recovery if there are fewer than diff --git a/src/osd/OSD.cc b/src/osd/OSD.cc index 185b66716a90..fa51c89936fa 100644 --- a/src/osd/OSD.cc +++ b/src/osd/OSD.cc @@ -923,7 +923,8 @@ OSD::OSD(CephContext *cct_, ObjectStore *store_, osd_compat(get_osd_compat_set()), state_lock(), state(STATE_INITIALIZING), op_tp(cct, "OSD::op_tp", cct->_conf->osd_op_threads, "osd_op_threads"), - op_sharded_tp(cct, "OSD::op_sharded_tp", cct->_conf->osd_op_num_sharded_pool_threads), + op_sharded_tp(cct, "OSD::op_sharded_tp", + cct->_conf->osd_op_num_threads_per_shard * cct->_conf->osd_op_num_shards), recovery_tp(cct, "OSD::recovery_tp", cct->_conf->osd_recovery_threads, "osd_recovery_threads"), disk_tp(cct, "OSD::disk_tp", cct->_conf->osd_disk_threads, "osd_disk_threads"), command_tp(cct, "OSD::command_tp", 1), @@ -967,7 +968,6 @@ OSD::OSD(CephContext *cct_, ObjectStore *store_, next_removal_seq(0), service(this) { - assert(cct->_conf->osd_op_num_sharded_pool_threads >= cct->_conf->osd_op_num_shards); monc->set_messenger(client_messenger); op_tracker.set_complaint_and_threshold(cct->_conf->osd_op_complaint_time, cct->_conf->osd_op_log_threshold);