]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mds: fix race between scatter gather and dirfrag export
authorYan, Zheng <zheng.z.yan@intel.com>
Sat, 15 Jun 2013 23:01:52 +0000 (07:01 +0800)
committerYan, Zheng <zheng.z.yan@intel.com>
Wed, 19 Jun 2013 17:45:19 +0000 (01:45 +0800)
commit15a5d37a90daca11d9dc0a581417d2a07b9d14ad
treec45e392f1711b6f18feb7f61faeaa181bc8031b2
parent7f5d6e5c4a3cf246ee55c7393c57d20b464b2e3b
mds: fix race between scatter gather and dirfrag export

If we gather dirty scatter lock state while corresponding dirfrag
is been exporting, we may receive different dirfrag states from
two MDS and we need to find which one is the newest. The solution
is adding a new variable "migrate seq" to dirfrag, increase it by
one when dirfrag's auth MDS changes. When gathering dirty scatter
lock state, use "migrate seq" to find the newest dirfrag state.

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