常见报错
更新时间:2024-03-07 19:06:53
PDF
报 Too many parititions for single insert block (more than 100)错误,怎么办?
问题现象
写入数据到 ClickHouse 时,上报 Too many parititions for single insert block (more than 100)
错误。
message: Too many partitions for single INSERT block (more than 100).
The limit is controlled by 'max_partitions_per_insert_block' setting.
Large number of partitions is a common misconception.
It will lead to severe negative performance impact, including slow server startup,
slow INSERT queries and slow SELECT queries. Recommended total number of partitions
for a table is under xx.x..xx.x. Please note, that partitioning is not intended to
speed up SELECT queries (ORDER BY key is sufficient to make range queries fast).
Partitions are intended for data manipulation (DROP PARTITION, etc)
可能原因
ClickHouse 受 max_partitions_per_insert_block
参数限制,每次写入的数据不能跨越超过 100 个 partition。
解决办法
调整 max_partitions_per_insert_block
参数值大小。ClickHouse 支持在线修改 max_partitions_per_insert_block
参数值,请参见修改配置参数。
注意 |
---|
|