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

mds: wait unlink to finish to avoid conflict when creating same dentries #46331

Merged
merged 2 commits into from Oct 11, 2022

Commits on Aug 12, 2022

  1. mds: wait unlink to finish to avoid conflict when creating same dentries

    If the previous unlink request has been delayed due to some reasons,
    and the new creating for the same dentry may fail or new open will
    succeeds but new contents wrote to it will be lost.
    
    The kernel client will make sure before the unlink getting the first
    reply it won't send the followed create requests for the same dentry.
    Here we need to make sure that before the first reply has been sent
    out the dentry must be marked as unlinking.
    
    Fixes: https://tracker.ceph.com/issues/55332
    Signed-off-by: Xiubo Li <xiubli@redhat.com>
    lxbsz committed Aug 12, 2022
    Copy the full SHA
    d4b9431 View commit details
    Browse the repository at this point in the history
  2. mds: clear the STATE_UNLINKING state when the unlink fails

    Signed-off-by: Xiubo Li <xiubli@redhat.com>
    lxbsz committed Aug 12, 2022
    Copy the full SHA
    417f247 View commit details
    Browse the repository at this point in the history