Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to configure ClickHouse Cluster

2025-04-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)05/31 Report--

This article is about how to configure ClickHouse clusters. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.

Note: we need to deploy ClickHouse in each node. For more information on how to deploy ClickHouse, see ClickHouse installation and deployment.

In general, we only need to modify Zookeeper storage and add nodes to configure ClickHouse clusters.

Node information host IPck110.10.0.1ck210.10.0.2ck310.10.0.3 configuration Zookeeper

Add the following configuration information to the / etc/clickhouse-server/config.xml file

Zk1 2181 zk2 2181 zk3 2181

Changing the configuration file mainly configures the information of connection Zookeeper. The index of each node cannot be repeated.

Note to add to the yandex node

Configure ClickHouse Cluster

Configuring ClickHouse cluster nodes requires configuring remote_servers nodes

Add the following configuration information to the / etc/clickhouse-server/config.xml file

1 true ck1 9000 ck2 9000 1 true ck2 9000 Ck3 9000 1 true ck3 9000 ck1 9000

Ck_cluster cluster identity, which can be specified by yourself, is required when creating a distribution table (the engine is Distributed).

The write weight value of each shard in weight has a higher probability of falling to the shard with higher weight value when data is written, which is all set to 1 here.

Whether internal_replication enables internal replication, that is, only one copy is written when the data is written, and the synchronization of the other replicas depends on the replication table and ZooKeeper asynchronously.

What we set up in shard shards is circular shards to ensure that one of the replicated nodes can run normally after a downtime.

Distribute the configuration to all nodes where ClickHouse is deployed for service restart

Thank you for reading! This is the end of this article on "how to configure ClickHouse clusters". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, you can share it for more people to see!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report