节点如何在ElasticSearch Cluster中工作

时间:2017-06-05 10:33:56

标签: elasticsearch

我有一个包含4个节点的集群。

节点1:   node.master:true   node.data:true 节点2:   node.master:true   node.data:true 节点3:   node.master:true   node.data:true 节点4:   node.master:false   node.data:false

和 discovery.zen.minimum_master_nodes:2。

现在,根据我的理解,将为群集选择单个主服务器,主服务器决定存储传入数据的位置和方式。

假设,节点2:关闭,永远不会回来。当节点2:关闭时,当重新选举发生时,群集仍将启动并运行。

但是存储在节点2中的数据会发生什么:。任何人都可以在这里解释一下这个流程。

1 个答案:

答案 0 :(得分:0)

如果节点2出现故障并且永不返回意味着您永远丢失了数据,除非您配置了副本。

如果每个分片都有一个副本,那么您将在不同的节点中拥有每个分片的额外副本。

因此,当节点2发生故障时,节点2数据将从节点2或节点1的副本服务器进行服务。

希望它有所帮助!

相关问题