mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-29 02:52:13 +00:00
Fix 01600_remerge_sort_lowered_memory_bytes_ratio flap
This commit is contained in:
parent
e7ffae89e9
commit
bf23bc6f0c
@ -1,17 +1,29 @@
|
|||||||
-- Check remerge_sort_lowered_memory_bytes_ratio setting
|
-- Check remerge_sort_lowered_memory_bytes_ratio setting
|
||||||
|
|
||||||
set max_memory_usage='4Gi';
|
set max_memory_usage='300Mi';
|
||||||
-- enter remerge once limit*2 is reached
|
-- enter remerge once limit*2 is reached
|
||||||
set max_bytes_before_remerge_sort='10Mi';
|
set max_bytes_before_remerge_sort='10Mi';
|
||||||
-- more blocks
|
-- more blocks
|
||||||
set max_block_size=40960;
|
set max_block_size=40960;
|
||||||
|
|
||||||
-- default 2, slightly not enough:
|
-- remerge_sort_lowered_memory_bytes_ratio default 2, slightly not enough
|
||||||
--
|
-- MergeSortingTransform: Re-merging intermediate ORDER BY data (20 blocks with 819200 rows) to save memory consumption
|
||||||
-- MergeSortingTransform: Memory usage is lowered from 1.91 GiB to 980.00 MiB
|
-- MergeSortingTransform: Memory usage is lowered from 186.25 MiB to 95.00 MiB
|
||||||
-- MergeSortingTransform: Re-merging is not useful (memory usage was not lowered by remerge_sort_lowered_memory_bytes_ratio=2.0)
|
-- MergeSortingTransform: Re-merging is not useful (memory usage was not lowered by remerge_sort_lowered_memory_bytes_ratio=2.0)
|
||||||
select number k, repeat(toString(number), 101) v1, repeat(toString(number), 102) v2, repeat(toString(number), 103) v3 from numbers(toUInt64(10e6)) order by k limit 400e3 format Null; -- { serverError 241 }
|
select number k, repeat(toString(number), 11) v1, repeat(toString(number), 12) v2 from numbers(toUInt64(3e6)) order by k limit 400e3 format Null; -- { serverError 241 }
|
||||||
select number k, repeat(toString(number), 101) v1, repeat(toString(number), 102) v2, repeat(toString(number), 103) v3 from numbers(toUInt64(10e6)) order by k limit 400e3 settings remerge_sort_lowered_memory_bytes_ratio=2. format Null; -- { serverError 241 }
|
select number k, repeat(toString(number), 11) v1, repeat(toString(number), 12) v2 from numbers(toUInt64(3e6)) order by k limit 400e3 settings remerge_sort_lowered_memory_bytes_ratio=2. format Null; -- { serverError 241 }
|
||||||
|
|
||||||
-- 1.91/0.98=1.94 is good
|
-- remerge_sort_lowered_memory_bytes_ratio 1.9 is good (need at least 1.91/0.98=1.94)
|
||||||
select number k, repeat(toString(number), 101) v1, repeat(toString(number), 102) v2, repeat(toString(number), 103) v3 from numbers(toUInt64(10e6)) order by k limit 400e3 settings remerge_sort_lowered_memory_bytes_ratio=1.9 format Null;
|
-- MergeSortingTransform: Re-merging intermediate ORDER BY data (20 blocks with 819200 rows) to save memory consumption
|
||||||
|
-- MergeSortingTransform: Memory usage is lowered from 186.25 MiB to 95.00 MiB
|
||||||
|
-- MergeSortingTransform: Re-merging intermediate ORDER BY data (20 blocks with 809600 rows) to save memory consumption
|
||||||
|
-- MergeSortingTransform: Memory usage is lowered from 188.13 MiB to 95.00 MiB
|
||||||
|
-- MergeSortingTransform: Re-merging intermediate ORDER BY data (20 blocks with 809600 rows) to save memory consumption
|
||||||
|
-- MergeSortingTransform: Memory usage is lowered from 188.13 MiB to 95.00 MiB
|
||||||
|
-- MergeSortingTransform: Re-merging intermediate ORDER BY data (20 blocks with 809600 rows) to save memory consumption
|
||||||
|
-- MergeSortingTransform: Memory usage is lowered from 188.13 MiB to 95.00 MiB
|
||||||
|
-- MergeSortingTransform: Re-merging intermediate ORDER BY data (20 blocks with 809600 rows) to save memory consumption
|
||||||
|
-- MergeSortingTransform: Memory usage is lowered from 188.13 MiB to 95.00 MiB
|
||||||
|
-- MergeSortingTransform: Re-merging intermediate ORDER BY data (20 blocks with 809600 rows) to save memory consumption
|
||||||
|
-- MergeSortingTransform: Memory usage is lowered from 188.13 MiB to 95.00 MiB
|
||||||
|
select number k, repeat(toString(number), 11) v1, repeat(toString(number), 12) v2 from numbers(toUInt64(3e6)) order by k limit 400e3 settings remerge_sort_lowered_memory_bytes_ratio=1.9 format Null;
|
||||||
|
Loading…
Reference in New Issue
Block a user