Skip to content

Commit 540a8ec

Browse files
committed
More docs re. removing cluster.initial_master_nodes (elastic#85948)
Ensures that on every page of the docs that mentions `cluster.initial_master_nodes` also mentions that this setting must be removed after bootstrapping completes.
1 parent 2b4963c commit 540a8ec

File tree

5 files changed

+21
-11
lines changed

5 files changed

+21
-11
lines changed

docs/reference/modules/discovery.asciidoc

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,7 @@ formation:
3232
themselves. As this auto-bootstrapping is
3333
<<modules-discovery-quorums,inherently unsafe>>, running a node in
3434
<<dev-vs-prod-mode,production mode>> requires bootstrapping to be
35-
explicitly configured via the
36-
<<modules-discovery-bootstrap-cluster,`cluster.initial_master_nodes`
37-
setting>>.
35+
<<modules-discovery-bootstrap-cluster,explicitly configured>>.
3836

3937
<<modules-discovery-adding-removing-nodes,Adding and removing master-eligible nodes>>::
4038

docs/reference/modules/discovery/bootstrapping.asciidoc

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,9 @@ node:
3131

3232
When you start a master-eligible node, you can provide this setting on the
3333
command line or in the `elasticsearch.yml` file. After the cluster has formed,
34-
this setting is no longer required. It should not be set for master-ineligible
35-
nodes, master-eligible nodes joining an existing cluster, or cluster restarts.
34+
remove this setting from each node's configuration. It should not be set for
35+
master-ineligible nodes, master-eligible nodes joining an existing cluster, or
36+
when restarting one or more nodes.
3637

3738
It is technically sufficient to set `cluster.initial_master_nodes` on a single
3839
master-eligible node in the cluster, and only to mention that single node in the

docs/reference/modules/discovery/discovery-settings.asciidoc

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,11 @@ setting, see <<single-node-discovery>>.
4343

4444
`cluster.initial_master_nodes`::
4545
(<<static-cluster-setting,Static>>)
46-
Sets the initial set of master-eligible nodes in a brand-new cluster. By default
47-
this list is empty, meaning that this node expects to join a cluster that has
48-
already been bootstrapped. See <<initial_master_nodes>>.
46+
Sets the initial set of master-eligible nodes in a brand-new cluster. By
47+
default this list is empty, meaning that this node expects to join a cluster
48+
that has already been bootstrapped. Remove this setting once the cluster has
49+
formed. Do not use this setting when restarting nodes or when adding new nodes
50+
to an existing cluster. See <<initial_master_nodes>>.
4951

5052
[discrete]
5153
==== Expert settings

docs/reference/setup/bootstrap-checks.asciidoc

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -253,3 +253,11 @@ properties:
253253
- `discovery.seed_hosts`
254254
- `discovery.seed_providers`
255255
- `cluster.initial_master_nodes`
256+
257+
Note that you should remove `cluster.initial_master_nodes` from the
258+
configuration after the cluster has started for the first time. Do not use this
259+
setting when restarting nodes or when adding new nodes to an existing cluster.
260+
Instead, configure `discovery.seed_hosts` or `discovery.seed_providers`. If you
261+
do not need any discovery configuration, for instance if running a single-node
262+
cluster, set `discovery.seed_hosts: []` to disable discovery and satisfy this
263+
bootstrap check.

docs/reference/setup/important-settings/discovery-settings.asciidoc

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,10 @@ mode, you must explicitly list the master-eligible nodes whose votes should be
5959
counted in the very first election. You set this list using the
6060
`cluster.initial_master_nodes` setting.
6161

62-
IMPORTANT: After the cluster forms successfully for the first time, remove the `cluster.initial_master_nodes` setting from each nodes'
63-
configuration. Do not use this setting when
64-
restarting a cluster or adding a new node to an existing cluster.
62+
IMPORTANT: After the cluster forms successfully for the first time, remove the
63+
`cluster.initial_master_nodes` setting from each node's configuration. Do not
64+
use this setting when restarting a cluster or adding a new node to an existing
65+
cluster.
6566

6667
[source,yaml]
6768
--------------------------------------------------

0 commit comments

Comments
 (0)