Node communication

I have 3 elastic nodes, I am trying to establish connection between 3 nodes, but not able to establish communication between nodes. Below is the elasticsearch.yml file, please let me what am I doing wrong.

# ======================== Elasticsearch Configuration =========================
#
# NOTE: Elasticsearch comes with reasonable defaults for most settings.
#       Before you set out to tweak and tune the configuration, make sure you
#       understand what are you trying to accomplish and the consequences.
#
# The primary way of configuring a node is via this file. This template lists
# the most important settings you may want to configure for a production cluster.
#
# Please consult the documentation for further information on configuration options:
# https://www.elastic.co/guide/en/elasticsearch/reference/index.html
#
# ---------------------------------- Cluster -----------------------------------
#
# Use a descriptive name for your cluster:
#
cluster.name: Elastic_Search
#
# ------------------------------------ Node ------------------------------------
#
# Use a descriptive name for the node:
#
node.name: node-3
#
# Add custom attributes to the node:
#
#node.attr.rack: r1
#
# ----------------------------------- Paths ------------------------------------
#
# Path to directory where to store the data (separate multiple locations by comma):
#
path.data: /var/lib/elasticsearch
#
# Path to log files:
#
path.logs: /var/log/elasticsearch
#
# ----------------------------------- Memory -----------------------------------
#
# Lock the memory on startup:
#
#bootstrap.memory_lock: true
#
# Make sure that the heap size is set to about half the memory available
# on the system and that the owner of the process is allowed to use this
# limit.
#
# Elasticsearch performs poorly when the system is swapping the memory.
#
# ---------------------------------- Network -----------------------------------
#
# By default Elasticsearch is only accessible on localhost. Set a different
# address here to expose this node on the network:
#
network.host: 0.0.0.0
#
# By default Elasticsearch listens for HTTP traffic on the first free port it
# finds starting at 9200. Set a specific HTTP port here:
#
http.port: 9200
#
# For more information, consult the network module documentation.
#
# --------------------------------- Discovery ----------------------------------
#
# Pass an initial list of hosts to perform discovery when this node is started:
# The default list of hosts is ["127.0.0.1", "[::1]"]
#
discovery.seed_hosts: ["172.16.12.11", "172.16.12.13","172.16.12.14"]

#
# Bootstrap the cluster using an initial set of master-eligible nodes:
#
cluster.initial_master_nodes: ["172.16.12.11"]
#
# For more information, consult the discovery and cluster formation module documentation.
#
# ---------------------------------- Various -----------------------------------
#
# Require explicit names when deleting indices:
#
action.destructive_requires_name: true


xpack.monitoring.enabled: 'true'
xpack.monitoring.collection.enabled: 'true'
xpack.monitoring.collection.interval: 30s

xpack.security.enabled: 'true'
xpack.security.audit.enabled: 'false'
xpack.security.transport.ssl.enabled: 'true'
#xpack.security.http.ssl.enabled: 'true'
#xpack.security.authc.api_key.enabled: 'true'
#xpack.watcher.enabled: 'false'

xpack.ilm.enabled: 'true'

What do your logs show?

It looks like you have enabled security but not created or configured any certificates. Please follow the guides around enabling security that are part of the documentation for your version.

Below are the logs,

localhost:~ # sudo tail -f /var/log/elasticsearch/Elastic_Search.log
[2021-09-15T09:39:21,260][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset
[2021-09-15T09:39:22,260][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset
[2021-09-15T09:39:23,260][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset
[2021-09-15T09:39:24,260][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset
[2021-09-15T09:39:25,260][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset
[2021-09-15T09:39:26,260][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset
[2021-09-15T09:39:27,261][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset
[2021-09-15T09:39:28,261][WARN ][o.e.d.PeerFinder         ] [node-2] address [17                                                                                        2.16.12.11:9300], node [null], requesting [false] connection failed: [][172.16.1                                                                                        2.11:9300] general node connection failure: handshake failed because connection                                                                                         reset

I have added the certificate to elasticsearch.yml and tried to restart but it fails. @warkolm @Christian_Dahlqvist

xpack.monitoring.enabled: 'true'
xpack.monitoring.collection.enabled: 'true'
xpack.monitoring.collection.interval: 30s

xpack.security.enabled: 'true'
xpack.security.audit.enabled: 'false'
xpack.security.transport.ssl.enabled: 'true'
xpack.security.transport.ssl.verification_mode: certificate
xpack.security.transport.ssl.client_authentication: required
xpack.security.transport.ssl.keystore.path: elastic-certificates.p12
xpack.security.transport.ssl.truststore.path: elastic-certificates.p12

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