分片shards管理

设置Analyze最大流量

SET global "stats.service.max_bytes_per_sec"='10m'

log filter

SET GLOBAL "stats.jobs_log_filter" = 'ended - started > 100';

ALTER TABLE .. REROUTE PROMOTE REPLICA

Routing失败重试

ALTER CLUSTER REROUTE RETRY FAILED

设置 recovery并行数量

SET GLOBAL "cluster.routing.allocation.node_concurrent_recoveries" = '100';

设置recovery写入量

SET GLOBAL "indices.recovery.max_bytes_per_sec" = '50mb';

设置并行rebalance个分片个数

cluster.routing.allocation.cluster_concurrent_rebalance
Default: 2
Runtime: yes
Defines how many concurrent rebalancing tasks are allowed across all nodes

设置一个节点主分片并行恢复数量

cluster.routing.allocation.node_initial_primaries_recoveries
Default: 4
Runtime: yes
Defines how many concurrent primary shard recoveries are allowed on a node.
Since primary recoveries use data that is already on disk (as opposed to inter-node recoveries), recovery should be fast and so this setting can be higher than

并行数

cluster.routing.allocation.node_concurrent_recoveries
Default: 2
Runtime: yes
Defines how many concurrent recoveries are allowed on a node.

decrease shards

alter table test.test_dt set ("routing.allocation.require._name"="10.10.3.19");
alter table test.test_dt set ("blocks.write"=true);
alter table test.test_dt set (number_of_shards = 21);
alter table test.test_dt set ("blocks.write" = false);

建表设置路由分片

CLUSTERED INTO 12 SHARDS WITH ( "number_of_routing_shards" = 48 )

切换表名

SWAP TABLE source TO target [ WITH ( expr = expr [ , ... ] ) ]

切表名

alter table user_voice.da_vocust_hotel_voice rename to da_vocust_hotel_voice_bk;
alter table user_voice.da_vocust_hotel_voice_tmp rename to da_vocust_hotel_voice;

Query Breaker

SET GLOBAL "indices.breaker.query.limit" = '3.0gb';

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容