[LU-14084] change 'lfs migrate' to use 'MIGRATION_NONBLOCK' by default Created: 28/Oct/20  Updated: 28/Oct/20

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

Type: Improvement Priority: Minor
Reporter: Andreas Dilger Assignee: WC Triage
Resolution: Unresolved Votes: 0
Labels: None

Issue Links:
Related
is related to LU-13645 Various data corruptions possible in ... Resolved
is related to LU-6785 Interop 2.7.0<->master sanity test_56... Resolved
Rank (Obsolete): 9223372036854775807

 Description   

Since Lustre 2.8 (patch https://review.whamcloud.com/16238 "LU-6785 utils: compatibility fix for lfs migrate") "lfs migrate" has used "--block" as the default (i.e. block writes to a file during migration) for compatibility with pre-2.8.0 servers (or earlier for EE releases).

Since very few servers are this old, it would be better to change the default to try and get the file lease first unless a new migration_flags = MIGRATION_BLOCK flag is set, and only try the grouplock if the lease fails and migration_flags = MIGRATION_NONBLOCK is not set.

This will also solve the problem that "lfs migrate" without the "--non-block" option fails for DoM files until patch https://review.whamcloud.com/39406 "LU-13645 ldlm: group locks for DOM IBIT lock" is landed (which is having some headwind itself):

lfs migrate: cannot get group lock: Invalid argument

This would also be less complex/risky to backport to 2.12.

It would also be useful to consolidate the migrate_block() and migrate_nonblock() code if possible, instead of having two nearly-identical functions.


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