Details
-
Technical task
-
Resolution: Unresolved
-
Medium
-
None
-
None
-
None
-
3
-
9223372036854775807
Description
Parity components in EC layouts have independent sizes on OST objects that differ from the file-level EOF. This causes:
- File size incorrectly includes parity component sizes
- EOF checks prevent reading full parity components during resync/verify
- Buffered reads are incorrectly constrained by file-level EOF
Solution
File size calculation: Modified lov_attr_get_composite() to skip parity components when calculating file size/kms. Parity components still contribute blocks for space accounting and timestamps to give the same behavior on resync as for regular mirrors.
EOF checks for parity IO: Added ci_parity_io flag to cl_io to track when IO targets a parity mirror. Set in lov_io_mirror_init() when a parity mirror is selected, inherited by sub-IOs.
Use ci_parity_io to bypass EOF checks in vvp_prep_size() and ll_direct_IO_impl(). This allows reading full parity component sizes regardless of file-level EOF.
One more: We must skip file_read_confine_iter() for all designated mirror IO - this is not ideal, but it's not possible to check if it's a parity mirror here since we don't have the layout yet at this spot. But this code is being removed soon, so we'll just rebase to get that and all will be well.