mirror of
https://github.com/ceph/ceph
synced 2025-03-11 02:39:05 +00:00
mds: fix root and mdsdir inodes' rsubdirs
inode rstat accounts inode itself. Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
This commit is contained in:
parent
5283d80d32
commit
da17394941
@ -348,6 +348,7 @@ void MDCache::create_empty_hierarchy(C_Gather *gather)
|
||||
|
||||
root->inode.dirstat = rootdir->fnode.fragstat;
|
||||
root->inode.rstat = rootdir->fnode.rstat;
|
||||
++root->inode.rstat.rsubdirs;
|
||||
root->inode.accounted_rstat = root->inode.rstat;
|
||||
|
||||
rootdir->mark_complete();
|
||||
@ -398,6 +399,7 @@ void MDCache::create_mydir_hierarchy(C_Gather *gather)
|
||||
|
||||
myin->inode.dirstat = mydir->fnode.fragstat;
|
||||
myin->inode.rstat = mydir->fnode.rstat;
|
||||
++myin->inode.rstat.rsubdirs;
|
||||
myin->inode.accounted_rstat = myin->inode.rstat;
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user