Skip to content

Checksum seek at end cause read failed #10340

@Lloyd-Pottiger

Description

@Lloyd-Pottiger

Bug Report

if (target_frame == current_frame)
{
pos = working_buffer.begin() + target_offset;
return offset;
}

If target_frame == current_frame && working_buffer is cleared. The pos is forwarded, then when we call next() after seek, we will read from an invalid memory.

The issue may lead to errors as follow

Code: 271, e.displayText() = DB::Exception: Data compressed with different methods, given method byte 0xbb, previous method byte 0x82: (while reading from DTFile: s3://s90592969/data/ks_37715_t_146/dmf_4432, column: 27:): while building stable index for index_ids=[2, 3], e.what() = DB::Exception

Maybe releated to this bug or not. Reading from S3 report errno=115

[2025/08/12 15:59:53.651 +00:00] [ERROR] [S3RandomAccessFile.cpp:118] ["Cannot read from istream, size=1048592 gcount=0 state=0x06 cur_offset=977287744 content_length=978111336 errno=115 errmsg=Operation now in progress cost=2896ns"] [source=s86062474/data/ks_90779_t_441/dmf_28961/7.dat] [thread_id=3925]

Metadata

Metadata

Assignees

No one assigned

    Labels

    affects-7.1This bug affects the 7.1.x(LTS) versions.affects-7.5This bug affects the 7.5.x(LTS) versions.affects-8.1This bug affects the 8.1.x(LTS) versions.affects-8.5This bug affects the 8.5.x(LTS) versions.component/storageseverity/moderatetype/bugThe issue is confirmed as a bug.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions