osd: Return the stored bitmap for secondary reads sent without attr_len #227

Open
koolkhel wants to merge 1 commits from koolkhel/vitastor:sec-read-bitmap-attr-len-0 into master

1 Commits

Author SHA1 Message Date
dd2249ac8f osd: Return the stored bitmap for secondary reads sent without attr_len
Since 51ecbadb a secondary OSD passes no bitmap to the blockstore when
attr_len is 0. That is right for writes, but the SEC_READ reply always
carries clean_entry_bitmap_size bytes of bitmap, so a read with
attr_len = 0 now returns an unfilled buffer instead of the object's
bitmap. Primaries before 51ecbadb (3.0.13 and older) send every read
with attr_len = 0. During a rolling upgrade they take that buffer as the
part's bitmap: chained reads of layered images then assert in
send_chained_read_results, and EC read-modify-write builds new bitmaps
from it.

Keep the attr_len check for writes only, so reads always fill the bitmap.
2026-12-04 18:10:24 +03:00