You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 21, 2021. It is now read-only.
Running a single node means that you have a single point of failure--there
4
-
is no redundancy.((("failover", "adding"))) Fortunately all we need to do to protect ourselves from data
3
+
Running a single node means that you have a single point of failure--there
4
+
is no redundancy.((("failover", "adding"))) Fortunately, all we need to do to protect ourselves from data
5
5
loss is to start another node.
6
6
7
-
.Starting a second node
7
+
.Starting a Second Node
8
8
***************************************
9
9
10
-
To test out what happens when you add a second((("nodes", "starting a second node"))) node, you can start a new node
10
+
To test what happens when you add a second((("nodes", "starting a second node"))) node, you can start a new node
11
11
in exactly the same way as you started the first one (see
12
-
<<running-elasticsearch>>), and from the same directory -- multiple nodes can
12
+
<<running-elasticsearch>>), and from the same directory. Multiple nodes can
13
13
share the same directory.
14
14
15
15
As long as the second node has the same `cluster.name` as the first node (see
16
16
the `./config/elasticsearch.yml` file), it should automatically discover and
17
17
join the cluster run by the first node. If it doesn't, check the logs to find
18
18
out what went wrong. It may be that multicast is disabled on your network, or
19
-
there is a firewall preventing your nodes from communicating.
19
+
that a firewall is preventing your nodes from communicating.
20
20
21
21
***************************************
22
22
23
23
If we start a second node, our cluster would look like <<cluster-two-nodes>>.
24
24
25
25
[[cluster-two-nodes]]
26
-
.A two-node cluster -- all primary and replica shards are allocated
26
+
.A two-node cluster--all primary and replica shards are allocated
27
27
image::images/elas_0203.png["A two-node cluster"]
28
28
29
-
The((("clusters", "two-node cluster"))) second node has joined the cluster and three _replica shards_ have ((("replica shards", "allocated to second node")))been
30
-
allocated to it--one for each primary shard. That means that we can lose
31
-
either node and all of our data will be intact.
29
+
The((("clusters", "two-node cluster"))) second node has joined the cluster, and three _replica shards_ have ((("replica shards", "allocated to second node")))been
30
+
allocated to it--one for each primary shard. That means that we can lose
31
+
either node, and all of our data will be intact.
32
32
33
-
Any newly indexed document will first be stored on a primary shard, then
34
-
copied in parallel to the associated replica shard(s). This ensures that our
35
-
document can be retrieved from a primary shard or from any of its replicas.
33
+
Any newly indexed document will first be stored on a primary shard, and then copied in parallel to the associated replica shard(s). This ensures that our document can be retrieved from a primary shard or from any of its replicas.
36
34
37
-
The `cluster-health` now ((("cluster health", "checking after adding second node")))shows a status of `green`, which means that all 6
38
-
shards (all 3 primary shards and all 3 replica shards) are active:
35
+
The `cluster-health` now ((("cluster health", "checking after adding second node")))shows a status of `green`, which means that all six
36
+
shards (all three primary shards and all three replica shards) are active:
0 commit comments