]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: during export list target second
authorSage Weil <sage@newdream.net>
Wed, 13 Apr 2011 18:27:21 +0000 (11:27 -0700)
committerSage Weil <sage@newdream.net>
Wed, 13 Apr 2011 20:58:19 +0000 (13:58 -0700)
We need to maintain the invariant that (dir_auth.first==whoami) == is_auth.

Signed-off-by: Sage Weil <sage@newdream.net>
src/mds/MDCache.cc
src/mds/Migrator.cc

index 196e372634f980b77eabb1a3b6674aa9176e9a53..26b7397153d3ee11b45ebaa92478cc634c826845 100644 (file)
@@ -2479,7 +2479,8 @@ void MDCache::handle_mds_recovery(int who)
        ++p) {
     CDir *dir = p->first;
 
-    if (dir->authority().first != who) continue;
+    if (dir->authority().first != who)
+      continue;
     assert(!dir->is_auth());
    
     // wake any waiters
index edaa84e6c429fd636da765dc91a925d961b05efe..aa33ee687009654b57fbb967e77509a10b2aaa6a 100644 (file)
@@ -903,7 +903,7 @@ void Migrator::export_go_synced(CDir *dir)
   assert(dir->get_cum_auth_pins() == 0);
 
   // set ambiguous auth
-  cache->adjust_subtree_auth(dir, dest, mds->get_nodeid());
+  cache->adjust_subtree_auth(dir, mds->get_nodeid(), dest);
 
   // take away the popularity we're sending.
   mds->balancer->subtract_export(dir, now);