Elasticsearch not able to form a cluster

Hi,

We have 3 nodes (Linux Ubuntu 20.04)

I have modified the /etc/hosts file to add node1 node2 and node3 as DNS with their IPs

I have installed elasticsearch but for some reason elasticsearch is not able to form a cluster.

I have tried ping and telnet on ports 9200 + 9300.

Following is the error I am facing:

[2023-05-19T05:12:03,463][WARN ][o.e.c.c.ClusterFormationFailureHelper] [DEMO-node1] master not discovered yet, this node has not previously joined a bootstrapped cluster, and this node must discover master-eligible nodes [node1] to bootstrap a cluster: have discovered [{DEMO-node1}{BoesH7LWSjeHZBbnDqZEgQ}{T9S0gp6eQyKIOsXf_LTpZg}{DEMO-node1}{NODE1_IP}{NODE1_IP:9300}{dimrt}, {DEMO-node2}{vW749uORTl2wmYzF5iPHKw}{WIVX0LYoQ3C9m7EMmU-GNQ}{DEMO-node2}{NODE2_IP}{NODE2_IP:9300}{dimrt}, {DEMO-node3}{j0mgoMMxTemVGBIM5jxxwA}{vOF9MtSiTseWrjQ_knURaA}{DEMO-node3}{NODE3_IP}{NODE3_IP:9300}{dimrt}]; discovery will continue using [NODE2_IP:9300, NODE3_IP:9300] from hosts providers and [{DEMO-node1}{BoesH7LWSjeHZBbnDqZEgQ}{T9S0gp6eQyKIOsXf_LTpZg}{DEMO-node1}{NODE1_IP}{NODE1_IP:9300}{dimrt}] from last-known cluster state; node term 0, last-accepted version 0 in term 0

Following is my elasticsearch.yml:

bootstrap.memory_lock: false
cluster.initial_master_nodes: node1
cluster.name: DEMO-CLUSTER
discovery.seed_hosts: node1, node2, node3
http.port: 9200
network.host: 0.0.0.0
xpack:
  security:
    authc:
      realms:
        native:
          native1:
            order: 0


#################################### Paths ####################################

path.data: /data/elasticsearch/data

path.logs: /data/elasticsearch/logs

path.repo: /data/elasticsearch/backup

action.auto_create_index: true

xpack.security.enabled: true

xpack.security.enrollment.enabled: true

xpack.monitoring.collection.enabled: true

xpack.monitoring.elasticsearch.collection.enabled: true

xpack.security.audit.enabled: true

node.roles: [ data, master, ingest, remote_cluster_client, transform ]
# BEGIN ANSIBLE MANAGED BLOCK
node.name: DEMO-node1
xpack.security.transport.ssl.enabled: true
xpack.security.transport.ssl.verification_mode: "certificate"
xpack.security.transport.ssl.key: "/etc/elasticsearch/security/node1/node1.key"
xpack.security.transport.ssl.certificate: "/etc/elasticsearch/security/node1/node1.crt"
xpack.security.transport.ssl.certificate_authorities: "/etc/elasticsearch/security/ca/ca.crt"

xpack.security.http.ssl.enabled: true
xpack.security.http.ssl.key: "/etc/elasticsearch/security/node1/node1.key"
xpack.security.http.ssl.certificate: "/etc/elasticsearch/security/node1/node1.crt"
xpack.security.http.ssl.certificate_authorities: "/etc/elasticsearch/security/ca/ca.crt"
# END ANSIBLE MANAGED BLOCK

Any help would be greatly apricated!!

Regards,
Neerajkumar

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