Details
-
Improvement
-
Resolution: Not a Bug
-
Minor
-
None
-
Lustre 2.12.6
-
None
-
3
-
9223372036854775807
Description
When a file is mirrored and the mirrored is broken file time stamps should be preserved. Here we see that ctime and mtime change to the mirror creation time.
Initial File:
# stat testfile
File: 'testfile'
Size: 59535 Blocks: 120 IO Block: 4194304 regular file
Device: 521e79ech/1377729004d Inode: 342273918398214817 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2022-02-14 15:48:45.000000000 -0800
Modify: 2022-02-14 15:48:45.000000000 -0800
Change: 2022-02-14 15:48:45.000000000 -0800
Now we mirror
# date; lfs mirror extend -N S 1M -c 1 -p hdd-pool testfile Mon Feb 14 15:50:27 PST 2022
State the File and layout
# stat testfile
File: 'testfile'
Size: 59535 Blocks: 120 IO Block: 4194304 regular file
Device: 521e79ech/1377729004d Inode: 342273918398214817 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2022-02-14 15:48:45.000000000 -0800
Modify: 2022-02-14 15:48:45.000000000 -0800
Change: 2022-02-14 15:48:45.000000000 -0800
Birth: -
pfe25 /nobackupp18/mhanafi # lfs getstripe testfile
testfile
lcm_layout_gen: 1
lcm_mirror_count: 2
lcm_entry_count: 4
lcme_id: 65537
lcme_mirror_id: 1
lcme_flags: init,prefer
lcme_extent.e_start: 0
lcme_extent.e_end: 268435456
lmm_stripe_count: 1
lmm_stripe_size: 16777216
lmm_pattern: raid0
lmm_layout_gen: 0
lmm_stripe_offset: 109
lmm_pool: ssd-pool
lmm_objects:
- 0: { l_ost_idx: 109, l_fid: [0x90000040a:0x53990:0x0] }
lcme_id: 65538
lcme_mirror_id: 1
lcme_flags: prefer
lcme_extent.e_start: 268435456
lcme_extent.e_end: 5368709120
lmm_stripe_count: -1
lmm_stripe_size: 16777216
lmm_pattern: raid0
lmm_layout_gen: 0
lmm_stripe_offset: -1
lmm_pool: ssd-pool
lcme_id: 65539
lcme_mirror_id: 1
lcme_flags: 0
lcme_extent.e_start: 5368709120
lcme_extent.e_end: EOF
lmm_stripe_count: 16
lmm_stripe_size: 16777216
lmm_pattern: raid0
lmm_layout_gen: 0
lmm_stripe_offset: -1
lmm_pool: hdd-pool
lcme_id: 131073
lcme_mirror_id: 2
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: 0
lmm_pool: hdd-pool
lmm_objects:
- 0: { l_ost_idx: 0, l_fid: [0x2c0000409:0x30c3e:0x0] }
Break the mirror and stat the file. File ctime and atime has changed.
date; lfs mirror split -d --mirror-id 1 testfile Mon Feb 14 15:51:31 PST 2022
# stat testfile
File: 'testfile'
Size: 59535 Blocks: 120 IO Block: 4194304 regular file
Device: 521e79ech/1377729004d Inode: 342273918398214817 Links: 1
Access: (0644/-rw-r--r--) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2022-02-14 15:50:27.000000000 -0800
Modify: 2022-02-14 15:48:45.000000000 -0800
Change: 2022-02-14 15:50:27.000000000 -0800
Birth: -
Attachments
Issue Links
- is duplicated by
-
LU-14508 lfs mirror operations do not preserve timestamps
- Resolved