Skip to content

Fix bug with bounded S3 reads and LowCardinality#34139

Merged
alesapin merged 10 commits intomasterfrom
fix_buf_s3_low_cardinality
Jan 31, 2022
Merged

Fix bug with bounded S3 reads and LowCardinality#34139
alesapin merged 10 commits intomasterfrom
fix_buf_s3_low_cardinality

Conversation

@alesapin
Copy link
Copy Markdown
Member

Changelog category (leave one):

  • Bug Fix (user-visible misbehaviour in official stable or prestable release)

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Fix bug which can rarely lead to error "Cannot read all data" while reading LowCardinality columns of MergeTree table engines family which stores data on remote file system like S3.

@alesapin alesapin added the pr-must-backport Pull request should be backported intentionally. Use this label with great care! label Jan 29, 2022
@robot-clickhouse robot-clickhouse added the pr-bugfix Pull request with bugfix, not backported by default label Jan 29, 2022
@timson
Copy link
Copy Markdown

timson commented Feb 1, 2022

Hi! I get this error on select query from table (partition by day) with partitions located on s3:

Received exception from server (version 21.12.3):
Code: 33. DB::Exception: Received from localhost:9000. DB::Exception: Received from chi-tesseract-01-tesseract-3-0:9000. DB::Exception: Cannot read all data. Bytes read: 0. Bytes expected: 8.: (while reading column ContainerName): (while reading from part /var/lib/clickhouse/disks/s3/data/flamedb/%2Einner%2Esamples_1day_local/20211230_0_139593_10/ from mark 32039 with max_rows_to_read = 8192): While executing MergeTreeThread. (CANNOT_READ_ALL_DATA)

column ContainerName is LowCardinality, so my question is my issue relevant to this bugfix?

@alesapin
Copy link
Copy Markdown
Member Author

alesapin commented Feb 1, 2022

Absolutely, this fix is exactly for your issue.

alesapin added a commit that referenced this pull request Feb 1, 2022
Backport #34139 to 21.12: Fix bug with bounded S3 reads and LowCardinality
alesapin added a commit that referenced this pull request Feb 1, 2022
Backport #34139 to 22.1: Fix bug with bounded S3 reads and LowCardinality
@UnamedRus
Copy link
Copy Markdown
Contributor

For LC(String) column

Received exception from server (version 22.3.3):
Code: 33. DB::Exception: Received from localhost:9000. DB::Exception: Cannot read all data. Bytes read: 0. Bytes expected: 8.: (while reading column user__username): (while reading from part /var/lib/clickhouse/disks/s3_disk/data/database/table/part_id_0_10_30/ from mark 528 with max_rows_to_read = 4304): While executing MergeTreeThread. (CANNOT_READ_ALL_DATA)

@kssenii
Copy link
Copy Markdown
Member

kssenii commented May 6, 2022

For LC(String) column
Received exception from server (version 22.3.3):
Code: 33. DB::Exception: Received from localhost:9000. DB::Exception: Cannot read all data. Bytes read: 0

#36763
#36856

@Felixoid Felixoid added the pr-backports-created Backport PRs are successfully created, it won't be processed by CI script anymore label Jul 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-backports-created Backport PRs are successfully created, it won't be processed by CI script anymore pr-bugfix Pull request with bugfix, not backported by default pr-must-backport Pull request should be backported intentionally. Use this label with great care!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants