]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mds: don't create bloom filter for incomplete dir
authorYan, Zheng <zheng.z.yan@intel.com>
Tue, 4 Dec 2012 08:09:47 +0000 (16:09 +0800)
committerSage Weil <sage@inktank.com>
Tue, 4 Dec 2012 22:50:11 +0000 (14:50 -0800)
commit3f69f7290d65b0551c24b2e8d95b713ca99a2303
treee8c4643da008e2206b38f8e5f5886da9ca3a7924
parent0756052cff542ab02d653b40c37a645b395f31b3
mds: don't create bloom filter for incomplete dir

Creating bloom filter for incomplete dir that was added by log
replay will confuse subsequent dir lookup and can create null
dentry for existing file. The erroneous null dentry confuses the
fragstat accounting and causes undeletable empty directory.

The fix is check if the dir is complete before creating the bloom
filter. For the MDCache::trim_non_auth{,_subtree} cases, just do
not call CDir::add_to_bloom because bloom filter is useless for
replica.

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