[LU-13748] 'lfs setstripe -C -1' stripes too widely Created: 03/Jul/20 Updated: 15/Dec/23 Resolved: 20/Jul/23 |
|
| Status: | Resolved |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | Lustre 2.16.0 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Andreas Dilger | Assignee: | Andreas Dilger |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | easy | ||
| Issue Links: |
|
||||||||||||||||||||||||
| Severity: | 3 | ||||||||||||||||||||||||
| Rank (Obsolete): | 9223372036854775807 | ||||||||||||||||||||||||
| Description |
|
Creating a file with overstriping using "-C -1" exceeds the maximum stripe count of 2000, resulting in a file that has an excessively-large xattr, which the client may have difficulty accessing: # lfs setstripe -E 128M -c 1 --comp-flags=prefer -E eof -C -1 /mnt/lustre/file0
# lfs getstripe /lustre/fs0a92/client/file129
/lustre/fs0a92/client/file129
lcm_layout_gen: 3
lcm_mirror_count: 1
lcm_entry_count: 2
lcme_id: 1
lcme_mirror_id: 0
lcme_flags: init,prefer
lcme_extent.e_start: 0
lcme_extent.e_end: 134217728
lmm_stripe_count: 1
lmm_stripe_size: 1048576
lmm_pattern: raid0
lmm_layout_gen: 0
lmm_stripe_offset: 7
lmm_objects:
- 0: { l_ost_idx: 7, l_fid: [0x100070000:0xcef:0x0] }
lcme_id: 2
lcme_mirror_id: 0
lcme_flags: init
lcme_extent.e_start: 134217728
lcme_extent.e_end: EOF
lmm_stripe_count: 2719
lmm_stripe_size: 1048576
lmm_pattern: raid0,overstriped
lmm_layout_gen: 0
lmm_stripe_offset: 9
lmm_objects:
- 0: { l_ost_idx: 9, l_fid: [0x100090000:0xe5:0x0] }
- 1: { l_ost_idx: 10, l_fid: [0x1000a0000:0xc5:0x0] }
- 2: { l_ost_idx: 11, l_fid: [0x1000b0000:0xc5:0x0] }
- 3: { l_ost_idx: 12, l_fid: [0x1000c0000:0xe5:0x0] }
- 4: { l_ost_idx: 13, l_fid: [0x1000d0000:0xe5:0x0] }
...
In some cases, running "lfs getstripe -v" on the file causes the client to crash. |
| Comments |
| Comment by Andreas Dilger [ 03/Jul/20 ] |
|
The MDS should impose a stripe count limit of LOV_MAX_STRIPE_COUNT = 2000 on a component. It also makes sense to limit the total xattr size below OBD_MAX_EA_SIZE. |
| Comment by Andreas Dilger [ 05/Oct/22 ] |
|
There was a maximum stripe_count limit added in |
| Comment by Gerrit Updater [ 05/Apr/23 ] |
|
"Andreas Dilger <adilger@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/c/fs/lustre-release/+/50532 |
| Comment by Gerrit Updater [ 19/May/23 ] |
|
"Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/c/fs/lustre-release/+/50532/ |
| Comment by Peter Jones [ 19/May/23 ] |
|
Landed for 2.16 |
| Comment by Andreas Dilger [ 20/May/23 ] |
|
This was only half the fix (to avoid crashing), still need to limit stripe count for -1. |
| Comment by Andreas Dilger [ 20/Jul/23 ] |
|
The "-C -1" stripe count was limited to LOV_MAX_STRIPE_COUNT by patch https://review.whamcloud.com/50250 " |