Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mimic: cephfs: client: unlink dentry for inode with llref=0 #29479

merged 1 commit into from Oct 17, 2019


Copy link

xiaoxichen commented Aug 5, 2019

when client get notification from MDS that a file has been deleted(via
getting CEPH_CAP_LINK_SHARED cap for inode with nlink = 0), if the client
hasnt touch the inode in the past, the ll_ref will be zero.

In previous code, we only call Client::unlink when ll_ref > 0, which is wrong
and will leave the dn in cache, keeping the caps and resulting the inode stays
in stray till the dn cache is dropped by kernel.

Under certain workload(write intensive and rotate intensive), this issue can cause
stray stacking to 100k+ and causeing huge space "leaking".


Signed-off-by: Xiaoxi CHEN <>
(cherry picked from commit c9ff6ab)
@xiaoxichen xiaoxichen added this to the mimic milestone Aug 5, 2019
@xiaoxichen xiaoxichen self-assigned this Aug 5, 2019
@xiaoxichen xiaoxichen changed the title Mimic: Client: unlink dentry for inode with llref=0 mimic: cephfs: client: unlink dentry for inode with llref=0 Aug 16, 2019
@smithfarm smithfarm requested a review from batrick Aug 20, 2019

This comment has been minimized.

Copy link

yuriw commented Oct 13, 2019

@yuriw yuriw merged commit b5c096f into ceph:mimic Oct 17, 2019
4 checks passed
4 checks passed
Docs: build check OK - docs built
Signed-off-by all commits in this PR are signed
Unmodified Submodules submodules for project are unmodified
make check make check succeeded
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
4 participants
You can’t perform that action at this time.