[LU-16423] 'lfs migrate' is creating multiple sets of objects Created: 22/Dec/22  Updated: 21/Jan/23  Resolved: 21/Jan/23

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

Type: Bug Priority: Minor
Reporter: Andreas Dilger Assignee: WC Triage
Resolution: Not a Bug Votes: 0
Labels: None

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

 Description   

When running "lfs migrate" on a PFL file, it appears that the client/MDS are needlessly creating multiple sets of OST objects:

# lfs setstripe -E 1M -c 1 -E 16M -c 4 -E eof -c -1 /mnt/testfs/pfl
# fallocate -L 4M /mnt/testfs/pfl
# lfs getstripe /mnt/testfs/pfl | grep l_ost_idx
      - 0: { l_ost_idx: 0, l_fid: [0x100000000:0xed5:0x0] }
      - 0: { l_ost_idx: 3, l_fid: [0x100030000:0x653:0x0] }
      - 1: { l_ost_idx: 1, l_fid: [0x100010000:0xb93:0x0] }
      - 2: { l_ost_idx: 2, l_fid: [0x100020000:0x62c:0x0] }
      - 3: { l_ost_idx: 0, l_fid: [0x100000000:0xed7:0x0] }
# lfs migrate /mnt/testfs/pfl
# lfs getstripe /mnt/testfs/pfl | grep l_ost_idx
      - 0: { l_ost_idx: 0, l_fid: [0x100000000:0xed8:0x0] }
      - 0: { l_ost_idx: 3, l_fid: [0x100030000:0x655:0x0] }
      - 1: { l_ost_idx: 1, l_fid: [0x100010000:0xb95:0x0] }
      - 2: { l_ost_idx: 2, l_fid: [0x100020000:0x62e:0x0] }
      - 3: { l_ost_idx: 0, l_fid: [0x100000000:0xeda:0x0] }
# lfs migrate /mnt/testfs/pfl
# lfs getstripe /mnt/testfs/pfl | grep l_ost_idx
      - 0: { l_ost_idx: 0, l_fid: [0x100000000:0xedb:0x0] }
      - 0: { l_ost_idx: 3, l_fid: [0x100030000:0x657:0x0] }
      - 1: { l_ost_idx: 1, l_fid: [0x100010000:0xb97:0x0] }
      - 2: { l_ost_idx: 2, l_fid: [0x100020000:0x630:0x0] }
      - 3: { l_ost_idx: 0, l_fid: [0x100000000:0xedd:0x0] }
# lfs migrate /mnt/testfs/pfl
# lfs getstripe /mnt/testfs/pfl | grep l_ost_idx
      - 0: { l_ost_idx: 0, l_fid: [0x100000000:0xede:0x0] }
      - 0: { l_ost_idx: 3, l_fid: [0x100030000:0x659:0x0] }
      - 1: { l_ost_idx: 1, l_fid: [0x100010000:0xb99:0x0] }
      - 2: { l_ost_idx: 2, l_fid: [0x100020000:0x632:0x0] }
      - 3: { l_ost_idx: 0, l_fid: [0x100000000:0xee0:0x0] }

As can be seen from the above, each "lfs migrate" command increments most OST FIDs by two, and OST0000 by three (because it has two separate objects for this file). The filesystem has 4 OSTs.



 Comments   
Comment by Andreas Dilger [ 21/Jan/23 ]

I tested this again on master with both "lfs migrate" and "lfs_migrate" and wasn't able to reproduce it.

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