Details

    • Bug
    • Resolution: Fixed
    • Critical
    • Lustre 2.12.0
    • Lustre 2.10.0, Lustre 2.11.0
    • None
    • 3
    • 9223372036854775807

    Description

      Under some situations lock revoke may not take effect, suppose a concurrent setattr on a striped directory and rename under this directory:
      1. setattr takes UPDATE lock of directory, but not unlock it yet (i.e., this lock is not downgraded to COS lock).
      2. a concurrent 'mv' under this directory will first getattr file by name, this getattr will revoke UPDATE lock of this directory, since this getattr is not a distributed operation, this revoke does nothing.
      3. setattr unlocks this UPDATE lock and downgrade it to COS mode, which notifies getattr that its lock is granted.
      4. rename tries to lock UPDATE lock of this directory, but this lock was revoked before (though nothing did), it won't revoke again, rename will wait until setattr transaction commit.

      Attachments

        Issue Links

          Activity

            [LU-11102] lock revoke may not take effect
            pjones Peter Jones added a comment -

            Landed for 2.12

            pjones Peter Jones added a comment - Landed for 2.12

            Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33458/
            Subject: LU-11102 ldlm: don't skip bl_ast for local lock
            Project: fs/lustre-release
            Branch: master
            Current Patch Set:
            Commit: 75a417fa0065d52a31215daaaaf41c0fa9751a89

            gerrit Gerrit Updater added a comment - Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/33458/ Subject: LU-11102 ldlm: don't skip bl_ast for local lock Project: fs/lustre-release Branch: master Current Patch Set: Commit: 75a417fa0065d52a31215daaaaf41c0fa9751a89

            Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33458
            Subject: LU-11102 ldlm: don't skip bl_ast for local lock
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: 78a841012f0a7c47ac88ef03a7e92f4832d65d57

            gerrit Gerrit Updater added a comment - Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33458 Subject: LU-11102 ldlm: don't skip bl_ast for local lock Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 78a841012f0a7c47ac88ef03a7e92f4832d65d57

            Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33199
            Subject: LU-11102 ldlm: don't skip bl_ast for local lock completely
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: 0cd33ff7d13718aa61428d7988dd3f019b84c1c2

            gerrit Gerrit Updater added a comment - Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33199 Subject: LU-11102 ldlm: don't skip bl_ast for local lock completely Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: 0cd33ff7d13718aa61428d7988dd3f019b84c1c2

            Commit 954cc6754b19a5eb4b9f717f79037c40baa87f3f contains the following issue - a local lock on server may be returned to a client via mdt_intent_lock_replace() and if it is blocking lock for some other waiting lock it must has LDLM_FL_AST_SENT flag while returned to the client, so client will call bl_ast on that lock. Otherwise the waiting lock will wait until timeout. That means we cannot just don't skip bl_ast for local locks until we sure it will not be sent to the client.

            tappro Mikhail Pershin added a comment - Commit 954cc6754b19a5eb4b9f717f79037c40baa87f3f contains the following issue - a local lock on server may be returned to a client via mdt_intent_lock_replace() and if it is blocking lock for some other waiting lock it must has LDLM_FL_AST_SENT flag while returned to the client, so client will call bl_ast on that lock. Otherwise the waiting lock will wait until timeout. That means we cannot just don't skip bl_ast for local locks until we sure it will not be sent to the client.

            reopen due to problems with patch 954cc6754b19a5eb4b9f717f79037c40baa87f3f

            tappro Mikhail Pershin added a comment - reopen due to problems with patch 954cc6754b19a5eb4b9f717f79037c40baa87f3f

            Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33066
            Subject: LU-11102 ldlm: revert commit 954cc675
            Project: fs/lustre-release
            Branch: master
            Current Patch Set: 1
            Commit: c0fe2f58b6c68896248087604031d311a6905afd

            gerrit Gerrit Updater added a comment - Mike Pershin (mpershin@whamcloud.com) uploaded a new patch: https://review.whamcloud.com/33066 Subject: LU-11102 ldlm: revert commit 954cc675 Project: fs/lustre-release Branch: master Current Patch Set: 1 Commit: c0fe2f58b6c68896248087604031d311a6905afd

            People

              laisiyao Lai Siyao
              laisiyao Lai Siyao
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: