我在集群中设置了两个主节点,但是只显示"elastic- master“而不显示”elastic-slave“。(第二个节点没有显示).How我可以解析它吗?我已经关注了Elasticsearch文档,但什么也没改变!
我的主机文件设置:
sudo nano /etc/hosts
192.168.143.30 elastic-master
192.168.143.23 elastic-slave我的配置文件:
# ---------------------------------- Cluster ------------------------------
cluster.name: elastic-a
# ------------------------------------ Node -------------------------------
node.name: elastic-master
node.master: true
node.data: true
# ---------------------------------- Network ------------------------------
network.host: 192.168.143.30
http.port: 9200
# --------------------------------- Discovery -----------------------------
discovery.seed_hosts: ["192.168.143.30","192.168.143.23"]
cluster.initial_master_nodes: ["elastic-slave", "elastic-master"]我的第二个配置文件:
# ---------------------------------- Cluster ------------------------------
cluster.name: elastic-a
# ------------------------------------ Node -------------------------------
node.name: elastic-slave
node.master: true
node.data: true
# ---------------------------------- Network ------------------------------
network.host: 192.168.143.23
http.port: 9200
# --------------------------------- Discovery -----------------------------
discovery.seed_hosts: ["192.168.143.30","192.168.143.23"]
cluster.initial_master_nodes: ["elastic-slave", "elastic-master"]发布于 2020-09-15 13:28:17
“首先停止服务(sudo服务弹性搜索停止)。删除数据(sudo rm -rf /var/lib/ elasticsearch /*),然后重新启动服务(sudo服务弹性搜索重新启动)。现在全部工作!!”答案可以在这里找到:Add nodes to make local cluster Elasticsearch [7.8]
https://stackoverflow.com/questions/63810517
复制相似问题