]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: properly propagate dirty dirstat to auth inode 1548/head
authorYan, Zheng <zheng.z.yan@intel.com>
Fri, 28 Mar 2014 04:57:29 +0000 (12:57 +0800)
committerYan, Zheng <zheng.z.yan@intel.com>
Fri, 28 Mar 2014 05:24:36 +0000 (13:24 +0800)
Propagate dirty dirstat to freezing auth inode if the inode is
already auth pinned by the Mutation. Otherwiese the dirstat can
be propagated to inode after client changes inode's mtime.

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

index a26633a44d216fcc07bbc7eb0119f80f8b88e823..54371fcb4b9ab8c95f17851343cc6e7667ef5745 100644 (file)
@@ -1983,8 +1983,8 @@ void MDCache::predirty_journal_parents(Mutation *mut, EMetaBlob *blob,
     }
 
     bool stop = false;
-    if (!pin->can_auth_pin() || pin->is_ambiguous_auth()) {
-      dout(10) << "predirty_journal_parents can't auth pin or ambig on " << *pin << dendl;
+    if (!pin->is_auth() || (!mut->is_auth_pinned(pin) && !pin->can_auth_pin())) {
+      dout(10) << "predirty_journal_parents !auth or ambig or can't authpin on " << *pin << dendl;
       stop = true;
     }