[LU-14514] lod_declare_layout_del() does not check for deletion of last non stale mirror Created: 11/Mar/21 Updated: 24/Mar/22 Resolved: 13/Dec/21 |
|
| Status: | Resolved |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | Lustre 2.15.0 |
| Type: | Bug | Priority: | Critical |
| Reporter: | John Hammond | Assignee: | Zhenyu Xu |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | bjhpflr | ||
| Issue Links: |
|
||||||||||||
| Severity: | 3 | ||||||||||||
| Rank (Obsolete): | 9223372036854775807 | ||||||||||||
| Description |
|
The lod layer does not check that we are not deleting the last non stale mirror of a file. |
| Comments |
| Comment by John Hammond [ 12/Mar/21 ] |
# cd /mnt/lustre
# echo XXX > f0
# lfs mirror extend -N -c1 f0
# echo XXXX > f0
# lfs getstripe f0
f0
lcm_layout_gen: 3
lcm_mirror_count: 2
lcm_entry_count: 2
lcme_id: 65537
lcme_mirror_id: 1
lcme_flags: init
lcme_extent.e_start: 0
lcme_extent.e_end: EOF
lmm_stripe_count: 1
lmm_stripe_size: 1048576
lmm_pattern: raid0
lmm_layout_gen: 0
lmm_stripe_offset: 1
lmm_objects:
- 0: { l_ost_idx: 1, l_fid: [0x100010000:0x15:0x0] }
lcme_id: 131073
lcme_mirror_id: 2
lcme_flags: init,stale
lcme_extent.e_start: 0
lcme_extent.e_end: EOF
lmm_stripe_count: 1
lmm_stripe_size: 1048576
lmm_pattern: raid0
lmm_layout_gen: 0
lmm_stripe_offset: 2
lmm_objects:
- 0: { l_ost_idx: 2, l_fid: [0x100020000:0x17:0x0] }
# lfs mirror split --mirror-id=1 f0
# lfs getstripe f0
f0
lcm_layout_gen: 4
lcm_mirror_count: 1
lcm_entry_count: 1
lcme_id: 131073
lcme_mirror_id: 2
lcme_flags: init,stale
lcme_extent.e_start: 0
lcme_extent.e_end: EOF
lmm_stripe_count: 1
lmm_stripe_size: 1048576
lmm_pattern: raid0
lmm_layout_gen: 0
lmm_stripe_offset: 2
lmm_objects:
- 0: { l_ost_idx: 2, l_fid: [0x100020000:0x17:0x0] }
# cat f0
cat: f0: Resource temporarily unavailable
#
# lfs setstripe --comp-set -I 2 --comp-flags=^stale f0
lfs setstripe: cannot clear 'stale' flags from component. Please use lfs-mirror-resync(1) instead
# lfs mirror resync f0
lfs mirror: 'f0' is not a FLR file.
|
| Comment by John Hammond [ 12/Mar/21 ] |
|
bobijam could you take a look at this? |
| Comment by Gerrit Updater [ 12/Mar/21 ] |
|
Bobi Jam (bobijam@hotmail.com) uploaded a new patch: https://review.whamcloud.com/42024 |
| Comment by Gerrit Updater [ 13/Dec/21 ] |
|
"Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/42024/ |
| Comment by Peter Jones [ 13/Dec/21 ] |
|
Landed for 2.15 |
| Comment by Gerrit Updater [ 20/Feb/22 ] |
|
"Andreas Dilger <adilger@whamcloud.com>" uploaded a new patch: https://review.whamcloud.com/46564 |
| Comment by Gerrit Updater [ 05/Mar/22 ] |
|
"Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/46564/ |