ELasticsearch initial master nodes using DNS

Hello,
Trying to setup a new Elastic Cluster with the latest and greatest version. I tried configuring the list to use hostnames and IP addresses can change. It seems ES doesnt like it when I use DNS. Is there another way I can set this by not using IP?

Thanks,
Ken

Can you be more precise? DNS resolution definitely works so I suspect there's something wrong with your setup instead. The docs say this:

Each address can be either an IP address or a hostname which resolves to one or more IP addresses via DNS.

cluster.initial_master_nodes:
  - hostname1
  - hostname2
  - hostname3 

I tried this and even put " " around them. I was able to test that I can hit the DNS from each host and even doing a curl with hostname works. It wasn't until i changed this to IP that the cluster initiated.

Ah sorry I see that you are asking about cluster.initial_master_nodes. This should be the node names not their network addresses. From the same docs page:

The initial master nodes should be identified by their node.name , which defaults to their hostname. Make sure that the value in cluster.initial_master_nodes matches the node.name exactly. If you use a fully-qualified domain name such as master-node-a.example.com for your node names then you must use the fully-qualified name in this list; conversely if node.name is a bare hostname without any trailing qualifiers then you must also omit the trailing qualifiers in cluster.initial_master_nodes .

ahhh that makes sense. I see what I am doing. Thank you, i was setting IP as the node.name . I will fix this to be more descriptive.

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