I am in need of help on setting up a 4 node elasticsearch servers. I have
installed and configured ES on all 4 nodes but I am lost as to what the
configuration in elasticsearch.yml will be:
if I want to have all 4 nodes both master and data
make node A act as primary shard while node B acts as its replica then
node C as primary shard while node D as its own replica.
Also there is not really any point in forcing shard types on specific
machines, unless you want to leverage some kind of awareness. A primary and
replica shard are the same thing other than a metadata flag that
differentiates them.
I am in need of help on setting up a 4 node elasticsearch servers. I have
installed and configured ES on all 4 nodes but I am lost as to what the
configuration in elasticsearch.yml will be:
if I want to have all 4 nodes both master and data
make node A act as primary shard while node B acts as its replica then
node C as primary shard while node D as its own replica.
you can make all nodes as master + data by setting following in
elasticsearch.yml file. i dont think/know if you can setup 2 nodes as
primary in cluster. For each index, you can set number of replica as 1 or
more, so ES will automatically move them to different nodes than primary
shard. i recommend using unicast for discovery as shown below if you have
static IPs.
On Wednesday, February 18, 2015 at 5:39:54 AM UTC-6, sysads wrote:
Hi
I am in need of help on setting up a 4 node elasticsearch servers. I have
installed and configured ES on all 4 nodes but I am lost as to what the
configuration in elasticsearch.yml will be:
if I want to have all 4 nodes both master and data
make node A act as primary shard while node B acts as its replica then
node C as primary shard while node D as its own replica.
You always want an odd number of master nodes (often 3), so I would
therefore recommend setting three of the four nodes to be master eligible
and leave the fourth as a pure data node. This will prevent the cluster
getting partitioned into two with equal number of master nodes on both
sides of the partition.
Best regards,
Christian
On Wednesday, February 18, 2015 at 11:39:54 AM UTC, sysads wrote:
Hi
I am in need of help on setting up a 4 node elasticsearch servers. I have
installed and configured ES on all 4 nodes but I am lost as to what the
configuration in elasticsearch.yml will be:
if I want to have all 4 nodes both master and data
make node A act as primary shard while node B acts as its replica then
node C as primary shard while node D as its own replica.
You always want an odd number of master nodes (often 3), so I would
therefore recommend setting three of the four nodes to be master eligible
and leave the fourth as a pure data node. This will prevent the cluster
getting partitioned into two with equal number of master nodes on both
sides of the partition.
Best regards,
Christian
On Wednesday, February 18, 2015 at 11:39:54 AM UTC, sysads wrote:
Hi
I am in need of help on setting up a 4 node elasticsearch servers. I
have installed and configured ES on all 4 nodes but I am lost as to what
the configuration in elasticsearch.yml will be:
if I want to have all 4 nodes both master and data
make node A act as primary shard while node B acts as its replica then
node C as primary shard while node D as its own replica.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.