Repository navigation
Increase S3 file cache size to fix flaky test - #95103
Merged
Merged
Conversation
The test `03514_grace_hash_join_logical_error` was failing sporadically with `NOT_ENOUGH_SPACE` error when running with S3 storage configuration. The grace hash join creates temporary files in the file cache, and with 1Gi limit the cache was filling up when running in parallel with other tests. Increase the cache size from 1Gi to 5Gi. Co-Authored-By: Claude Opus 4.5 <[email protected]>
Contributor
huldarchen
pushed a commit
to huldarchen/ClickHouse
that referenced
this pull request
Oct 11, 2026
On the s3-storage stateless lanes all temporary data goes into cached_s3 (temporary_data_in_cache). The cache has no cache_policy, so it uses the default SLRU with slru_size_ratio 0.6, and new (temporary) file segments can only use the probationary share: 40% of max_size, i.e. 2 GiB of 5Gi. Segments that are being written are not evictable, so every concurrent spill of a parallel run shares a hard 2 GiB pool while the protected 3 GiB stays unused for them. With the ParallelReplicas lane settings 04033_tpc_ds_q04 spills 1.55 GiB and 04033_tpc_ds_q11 0.71 GiB (failing jobs' query_log); whichever of the two reserves past 2 GiB first fails with NOT_ENOUGH_SPACE "for temporary file: reason cannot evict enough space ... Ephemeral hold 2.00 GiB". They started overlapping when ClickHouse#123790 moved the ParallelReplicas + s3 configuration from amd_llvm_coverage (q04 skipped there) to arm_binary. 10Gi gives a 4 GiB probationary pool; the sum of every test's maximum spill in the failing jobs is about 3.5 GiB. Same knob as ClickHouse#95103. Validated with a master build, local MinIO and two configs that differ only in this file: a 2.45 GiB GROUP BY spill fails 3/3 on 5Gi and passes 3/3 on 10Gi (on 10Gi it fails at exactly 4.00 GiB); q04 + q11 run together failed 12/20 on 5Gi and passed 20/20 and 100/100 on 10Gi. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The test
03514_grace_hash_join_logical_errorwas failing sporadically withNOT_ENOUGH_SPACEerror when running with S3 storage configuration. The grace hash join creates temporary files in the file cache, and with 1Gi limit the cache was filling up when running in parallel with other tests.Increase the cache size from 1Gi to 5Gi.
Changelog category (leave one):
See https://s3.amazonaws.com/clickhouse-test-reports/json.html?REF=master&sha=a1b25f3f4beb3ba49aa3b73671cc244185331b86&name_0=MasterCI&name_1=Stateless%20tests%20%28amd_binary%2C%20ParallelReplicas%2C%20s3%20storage%2C%20parallel%29&name_1=Stateless%20tests%20%28amd_binary%2C%20ParallelReplicas%2C%20s3%20storage%2C%20parallel%29
Version info
26.1.1.855