LU-13375 flr: inherit the correct layout by "mirror extend -N"
For PFL files, if stripe information is not specified to the cmd
"lfs mirror extend -N", the layout of the last initialized comp of
this file should be inherited by the mirror.
For example,
lcm_mirror_count: 2
lcm_entry_count: 4
lcme_id: 65537
lcme_mirror_id: 1
lcme_flags: init
lcme_extent.e_start: 0
lcme_extent.e_end:
10485760
lmm_stripe_count: 1
lmm_stripe_size: 1048576
lmm_objects:
- 0: { l_ost_idx: 2, l_fid: [0x100020000:0x102:0x0] }
lcme_id: 65538
lcme_mirror_id: 1
lcme_flags: init
lcme_extent.e_start:
10485760
lcme_extent.e_end:
20971520
lmm_stripe_count: 2
lmm_stripe_size: 2097152
lmm_objects:
- 0: { l_ost_idx: 3, l_fid: [0x100030000:0x91:0x0] }
- 1: { l_ost_idx: 0, l_fid: [0x100000000:0x13d:0x0] }
lcme_id: 65539
lcme_mirror_id: 1
lcme_flags: 0
lcme_extent.e_start:
20971520
lcme_extent.e_end: EOF
lmm_stripe_count: -1
lmm_stripe_size: 4194304
lcme_id: 131073
lcme_mirror_id: 2
lcme_flags: init
lcme_extent.e_start: 0
lcme_extent.e_end: EOF
lmm_stripe_count: 2
lmm_stripe_size: 2097152
lmm_pool: archive
lmm_objects:
- 0: { l_ost_idx: 1, l_fid: [0x100010000:0x17c:0x0] }
- 1: { l_ost_idx: 2, l_fid: [0x100020000:0x103:0x0] }
sanity-flr.sh test_0f is modified to verify this patch.
Signed-off-by: Emoly Liu <emoly@whamcloud.com>
Change-Id: If7db3ec7ce9414a04a32e9995ba24f322fb93ab5
Reviewed-on: https://review.whamcloud.com/38079
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>