]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mds: set the correct WRLOCK flag always in wrlock_force() 57085/head
authorXiubo Li <xiubli@redhat.com>
Thu, 25 Apr 2024 04:06:25 +0000 (12:06 +0800)
committerXiubo Li <xiubli@redhat.com>
Wed, 8 May 2024 01:12:37 +0000 (09:12 +0800)
commit9a6f249b96faed085a7dea251b0fd81a28330025
tree2c8271656faa6d6343ac6435e0b73df073ff50f1
parent1d815ceabb47f66b7ffcffd2e7bff487b4bab808
mds: set the correct WRLOCK flag always in wrlock_force()

The wrlock is not like the xlock, which needs to be acquired in
the CInode's auth always, and it is based on the CDir's auths instead.

When a remote_wrlock is acquired and the local MDS will add a lock
item and marks it as REMOTE_WRLOCK. And later when the local MDS try
to force wrlock in the emplace_lock() will just return the existing
lock item without updating the WRLOCK flag. So when cleaning the
requests later it will just release the remote locks and then removes
lock items directly, which will miss releasing the local wrlock
reference.

Fixes: https://tracker.ceph.com/issues/65630
Signed-off-by: Xiubo Li <xiubli@redhat.com>
src/mds/Locker.cc