A few questions about the fundamentals of the use of cluster.initial_master_nodes
and cluster bootstrapping and master election. The documentation mentions that the cluster.initial_master_nodes
setting is used for initial cluster bootstrapping and master election and then is otherwise ignored moving forward. However, in the case of a cluster restart or start/stop, wouldn't this bootstrapping process occur again? In other words is the bootstrapping process something could happen one or more times during the life time of my cluster for any reason, requiring reuse of the cluster.initial_master_nodes
settings?
For context, I'm working on setting up an ES 7 cluster on GCE and wanted to use a list of cnames for the cluster.initial_master_nodes
setting in the elasticsearch.yml
. The node.name
property is set to the A record name for the instance and, as you'd expect, I ran into the error that the documentation said I would get. For now, I set the cluster.initial_master_nodes
to be the explicit A record names of three of our instances and things are working.
Why do the cluster.initial_master_nodes
and node.name
s need to match? More importantly, given that they do need to match, what is the recommended way to manage master nodes rotating in and out? My intent was that if the individual instances that are designated as masters fail and are replaced with instances of a different name, we can just point the cname to a new instance without requiring a configuration update.
I suspect I have some misunderstanding of how this setting is used and/or of some Elasticsearch fundamentals. If cluster.initial_master_nodes
is truly only needed exactly once for a cluster, that makes my concern about the master management problem a lot easier
Thanks in advance!