Unable to setup the elastic cluster

Team, i was trying to setup a elasticsearch cluster using vm's on local machine
i was able to setup the configuration and started the service but i couldn't able to form the cluster
as it shows
#curl localhost:9200/_cat/nodes
[root@master01 elasticsearch]# curl localhost:9200/_cat/nodes?v
ip heap.percent ram.percent cpu load_1m load_5m load_15m node.role master name
192.168.29.79 14 92 22 0.34 0.27 0.28 im * master01
[root@master01 elasticsearch]#

working with 3 nodes and here are my configs on them
elasticsearch version : 7.6.0

Master01: 192.168.29.79
cluster.name: my-application
node.name: master01
path.data: /var/lib/elasticsearch
path.logs: /var/log/elasticsearch
network.host: local, site also tried with [local, site]
http.port: 9200
discovery.seed_hosts: ["192.168.29.79"]
cluster.initial_master_nodes: ["master01"]
node.master: true
node.data: false
node.ingest: true
node.ml: false

node01 : 192.168.29.9

cluster.name: my-application
node.name: node01
path.data: /var/lib/elasticsearch
path.logs: /var/log/elasticsearch
network.host: local, site also tried with [local, site]
http.port: 9200
discovery.seed_hosts: ["192.168.29.79"]
cluster.initial_master_nodes: ["master01"]
node.master: false
node.data: true
node.ingest: true
node.ml: false

node02 : 192.168.29.210

cluster.name: my-application
node.name: node02
path.data: /var/lib/elasticsearch
path.logs: /var/log/elasticsearch
network.host: local, site also tried with [local, site]
http.port: 9200
discovery.seed_hosts: ["192.168.29.79"]
cluster.initial_master_nodes: ["master01"]
node.master: false
node.data: true
node.ingest: true
node.ml: false

all 3 nodes ping each other

[root@master01 elasticsearch]# ping 192.168.29.9
PING 192.168.29.9 (192.168.29.9) 56(84) bytes of data.
64 bytes from 192.168.29.9: icmp_seq=1 ttl=64 time=0.429 ms

[root@master01 elasticsearch]# ping 192.168.29.210
PING 192.168.29.210 (192.168.29.210) 56(84) bytes of data.
64 bytes from 192.168.29.210: icmp_seq=1 ttl=64 time=0.524 ms
64 bytes from 192.168.29.210: icmp_seq=2 ttl=64 time=1.39 ms

while iwas checking the log s i see that the discovery type zen but no where i setup ths option , i kept "local, site"

[2023-11-22T06:39:51,819][INFO ][o.e.d.DiscoveryModule ] [master01] using discovery type [zen] and seed hosts providers [settings] and no error logs i found.

also i tried to ad the discovery type to multi-node but the elastic service failing to start.

could you please help me.

if you're in server (es01) then discovery.seed_hosts=es02,es03
check other server logs as well

Thank you Vijay for your support!

my master node is : master01 ["192.168.29.79"]
data nodes:
node01 ["192.168.29.9"]
node02 ["192.168.29.210"]

service started in all the nodes but not adding to cluster.
here i found few logs , it seems node02 and 01 are trying to connect master using the port no 9300 instead of 9200 and not enabled any security things.

[2023-11-22T05:48:03,764][WARN ][o.e.c.c.ClusterFormationFailureHelper] [node02] master not discovered yet: have discovered [{node02}{7uSw1qh6T_6_W4LG3w95lg}{pC2r2HVkTG2o6sysfSNt6g}{192.168.29.210}{192.168.29.210:9300}{di}{xpack.installed=true}]; discovery will continue using [192.168.29.79:9300] from hosts providers and from last-known cluster state; node term 1, last-accepted version 19 in term 1

Also found the systems are tryinh to discover using "zen" i think it soppose to be local.site as i mention network host.

[2023-11-22T06:39:51,819][INFO ][o.e.d.DiscoveryModule ] [master01] using discovery type [zen] and seed hosts providers [settings]

This cannot be _local_ as this means that the Elasticsearch service will listen only on 127.0.0.1.

You need to change it to _site_ or 0.0.0.0, I would use 0.0.0.0 to make it clear that the service will bind to every ip address in the node, you can also use the ip address of the host, for example 192.168.29.79.

Also, keep in mind that 7.6 is not supported anymore, if you want to use version 7.X you should use 7.17.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.