]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
OSD: only start osd_recovery_max_single_start at once
authorSamuel Just <sam.just@inktank.com>
Tue, 6 Aug 2013 20:02:24 +0000 (13:02 -0700)
committerSamuel Just <sam.just@inktank.com>
Tue, 6 Aug 2013 20:51:51 +0000 (13:51 -0700)
Signed-off-by: Samuel Just <sam.just@inktank.com>
src/common/config_opts.h
src/osd/OSD.cc

index f2afefc92e20b5ea090c3e204e7faf572ebc0b88..f67d0d1237dd50723b757f28a38f059ce7796a9f 100644 (file)
@@ -426,7 +426,8 @@ OPTION(osd_default_data_pool_replay_window, OPT_INT, 45)
 OPTION(osd_preserve_trimmed_log, OPT_BOOL, false)
 OPTION(osd_auto_mark_unfound_lost, OPT_BOOL, false)
 OPTION(osd_recovery_delay_start, OPT_FLOAT, 0)
-OPTION(osd_recovery_max_active, OPT_INT, 5)
+OPTION(osd_recovery_max_active, OPT_INT, 60)
+OPTION(osd_recovery_max_single_start, OPT_INT, 10)
 OPTION(osd_recovery_max_chunk, OPT_U64, 8<<20)  // max size of push chunk
 OPTION(osd_push_per_object_cost, OPT_U64, 1000)  // push cost per object
 OPTION(osd_max_push_cost, OPT_U64, 8<<20)  // max size of push message
index 987f8354c805be007f82691d575b8111d1d56b92..7a2417cf248a0dae721d637020814f4bf4dd0495 100644 (file)
@@ -6636,7 +6636,8 @@ void OSD::do_recovery(PG *pg, ThreadPool::TPHandle &handle)
 {
   // see how many we should try to start.  note that this is a bit racy.
   recovery_wq.lock();
-  int max = g_conf->osd_recovery_max_active - recovery_ops_active;
+  int max = MAX(g_conf->osd_recovery_max_active - recovery_ops_active,
+               g_conf->osd_recovery_max_single_start);
   if (max > 0) {
     dout(10) << "do_recovery can start " << max << " (" << recovery_ops_active << "/" << g_conf->osd_recovery_max_active
             << " rops)" << dendl;