[LU-16005] PCC: check first before set PCC-RO on a file Created: 12/Jul/22  Updated: 12/Jul/22

Status: Open
Project: Lustre
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Minor
Reporter: Qian Yingjin Assignee: Qian Yingjin
Resolution: Unresolved Votes: 0
Labels: None

Severity: 3
Rank (Obsolete): 9223372036854775807

 Description   

MDT should take a CR layout lock against the file object first to check whether the file is already PCC-RO cached. If so, return immediately; Otherwise, take an EX lock on the file to update the FLR PCC-RO state accordingly. By this check, it can avoid heavy lock contention and unnecessary revocation of the layout lock granted to the other clients when multiple processes from many clients perform read-only attach on a shared file simultaneously.

It also adds the layout intent write (LAYOUT_INTENT_PCCRO_SET and LAYOUT_INTENT_PCCRO_CLEAR) with FMODE_WRITE flag, so that the conflict lock can be revoked via the ELC strategy, avoiding unnecessary lock traffic.



 Comments   
Comment by Gerrit Updater [ 12/Jul/22 ]

"Yingjin Qian <qian@ddn.com>" uploaded a new patch: https://review.whamcloud.com/47936
Subject: LU-16005 pcc: check first before set PCC-RO on a file
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: c99c9a21cd081c23ae72accef123841ed3427a4a

Generated at Sat Feb 10 03:23:09 UTC 2024 using Jira 9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c.