[LU-9385] mdt_add_dirty_flag() should not use MDS_INODELOCK_XATTR Created: 21/Apr/17  Updated: 31/Aug/17  Resolved: 09/May/17

Status: Resolved
Project: Lustre
Component/s: None
Affects Version/s: None
Fix Version/s: Lustre 2.10.0

Type: Bug Priority: Minor
Reporter: John Hammond Assignee: John Hammond
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Duplicate
Related
Severity: 3
Rank (Obsolete): 9223372036854775807

 Description   

Clients use the {{MDS_HSM_STATE_

{GET,SET}

}} RPCs to get and set the HSM state of a file and not the HSM xattr. Thus the MDT should not use MDS_INODELOCK_XATTR to protect updates to the HSM state. A local (preferably already existing) mutex or semaphore in the MDT object should be used instead.



 Comments   
Comment by Gerrit Updater [ 27/Apr/17 ]

John L. Hammond (john.hammond@intel.com) uploaded a new patch: https://review.whamcloud.com/26870
Subject: LU-9385 mdt: remove XATTR locking from mdt_add_dirty_flag()
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: 193dbfa42674074555606eae0f8b38981b025a6b

Comment by Gerrit Updater [ 09/May/17 ]

Oleg Drokin (oleg.drokin@intel.com) merged in patch https://review.whamcloud.com/26870/
Subject: LU-9385 mdt: remove XATTR locking from mdt_add_dirty_flag()
Project: fs/lustre-release
Branch: master
Current Patch Set:
Commit: e5eec257c4daf9e2f538f13c7f7ff121acbc0195

Comment by Peter Jones [ 09/May/17 ]

Landed for 2.10

Comment by John Hammond [ 25/May/17 ]

Note that mdt_add_dirty_flag() is called from the close path. As explained in mdc_close():

        /* To avoid a livelock (bug 7034), we need to send CLOSE RPCs to a                
         * portal whose threads are not taking any DLM locks and are therefore            
         * always progressing */
        req->rq_request_portal = MDS_READPAGE_PORTAL;
        ptlrpc_at_set_req_timeout(req);

And so this is another instance of https://bugzilla.lustre.org/show_bug.cgi?id=7034.

Generated at Sat Feb 10 02:25:44 UTC 2024 using Jira 9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c.