]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: re-issue caps when recovering MDS becomes active
authorYan, Zheng <zyan@redhat.com>
Sun, 7 Jun 2015 02:47:47 +0000 (10:47 +0800)
committerYan, Zheng <zyan@redhat.com>
Tue, 18 Aug 2015 08:49:50 +0000 (16:49 +0800)
this makes sure the recovering MDS handle cap flushes re-sent by
clients before re-issuing caps.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
src/mds/MDSRank.cc

index dc550989e28667a1c338be9716c17d5c42c56d0a..ac07b16512736e1364b1c28fbc19609095075e9d 100644 (file)
@@ -1254,6 +1254,9 @@ void MDSRank::active_start()
   mdcache->clean_open_file_lists();
   mdcache->export_remaining_imported_caps();
   finish_contexts(g_ceph_context, waiting_for_replay);  // kick waiters
+
+  mdcache->reissue_all_caps();
+
   finish_contexts(g_ceph_context, waiting_for_active);  // kick waiters
 }
 
@@ -1275,8 +1278,6 @@ void MDSRank::recovery_done(int oldstate)
   mdcache->start_recovered_truncates();
   mdcache->do_file_recover();
 
-  mdcache->reissue_all_caps();
-  
   // tell connected clients
   //bcast_mds_map();     // not anymore, they get this from the monitor