]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: encode dirfrag base in cache rejoin ack
authorYan, Zheng <zheng.z.yan@intel.com>
Sat, 3 May 2014 00:53:01 +0000 (08:53 +0800)
committerYan, Zheng <zheng.z.yan@intel.com>
Tue, 6 May 2014 23:10:16 +0000 (07:10 +0800)
Makes sure recovering MDS get uptodate fragstat/rstat for subtree root
dirfrags. it's required the codes that fix-up inode's fragstat/rstat.

Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
src/mds/MDCache.cc

index 82fb44242c665a207ceeb4818b0dd6f003143a78..342eca0a1fb271464e82ee313913c83d96ad98a5 100644 (file)
@@ -4054,8 +4054,10 @@ void MDCache::handle_cache_rejoin_weak(MMDSCacheRejoin *weak)
        dirs_to_share.insert(dir);
        unsigned nonce = dir->add_replica(from);
        dout(10) << " have " << p->frag << " -> " << fg << " " << *dir << dendl;
-       if (ack)
+       if (ack) {
          ack->add_strong_dirfrag(dir->dirfrag(), nonce, dir->dir_rep);
+         ack->add_dirfrag_base(dir);
+       }
       }
     }
   }