# Configure a search load balancer node

**URL:** <https://discuss.elastic.co/t/configure-a-search-load-balancer-node/12512>\
**Category:** Elasticsearch\
**Created:** [June 21, 2013, 3:13pm UTC](https://discuss.elastic.co/t/configure-a-search-load-balancer-node/12512 "2013-06-21T15:13:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vannya](https://avatars.discourse-cdn.com/v4/letter/v/e495f1/32.png) [@vannya](https://discuss.elastic.co/u/vannya)\
**Post date:** [June 21, 2013, 3:13pm UTC](https://discuss.elastic.co/t/configure-a-search-load-balancer-node/12512/1 "2013-06-21T15:13:05Z")

</div>

Hi all,

I have 2 instances of elasticsearch in 2 different machines in different  
networks (ip-A and ip-B). They have the same cluster name, but I don't want  
them to replicate data between them, so I disabled all discovery  
configurations by setting discovery.zen.ping.multicast.enabled to false in  
both (the ideal situation would be they don't even know each other, making  
them completely unaware of each other). I would like then to have another  
instance of elasticsearch to function as a search load balancer, to allow  
the search requests to enter through it and then search in the other 2  
instances to fetch data from them and aggregate results.

Is this possible? I already tryed to configure the search load balancer  
like this:

node.master: false  
node.data: false  
discovery.zen.ping.unicast.hosts: ["ip-A", "ip-B"]

but it only connects to one of them returning only results from the one it  
is connected to.

Any suggestions?

Thanks,

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Ben\_Hundley](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ben_hundley/32/1853_2.png) [@Ben\_Hundley](https://discuss.elastic.co/u/Ben_Hundley)\
**Post date:** [June 21, 2013, 5:13pm UTC](https://discuss.elastic.co/t/configure-a-search-load-balancer-node/12512/2 "2013-06-21T17:13:47Z")

</div>

Why is it that you are wanting your data nodes to be unaware of each other? If truly your goal is to prevent replication between nodes, setting number\_of\_replicas to 0 on your index settings should inherently achieve this.

And if you have multiple shards, such as having 1 shard on each of your 2 data nodes, communication will need to be open for transport between nodes (which is unrelated to multicast discovery -- discovery is only used during master election). If the data to be returned in a search response is located on the node opposite of where the load balancer sent the search request, the receiving node must request the data from the other node. That is of course, only if you do not have a replica -- which would allow each node to respond to any search request directly.

As far as configuring a load balancing (or client) node, these are the settings I use on the client nodes (which in my case are API servers):

_node:  
data: false  
client: true_

You can still set master to false, if needed in your situation of course. I just happen to use specific data nodes as master in my case.

---

<div class="post-metadata">

**Author:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [June 24, 2013, 2:46pm UTC](https://discuss.elastic.co/t/configure-a-search-load-balancer-node/12512/3 "2013-06-24T14:46:32Z")

</div>

Hey,

you should decide at some time, if you want to have a cluster or not. Your  
scenario sounds somewhat hybrid. Maybe it makes sense to have two different  
elasticsearch clusters (with two different cluster names) in two different  
subnets, which yield the same data and simply put an nginx in front of it  
in order to do round robin loadbalancing. Anyway I still do not see a point  
of having completely independent clusters around and then again kind of  
syncing them at application level - but maybe that's a weird requirement.

Anyway, you have to go HTTP instead of using an elasticsearch node and its  
transport protocol for load balancing between two unknown clusters.

--Alex

On Fri, Jun 21, 2013 at 5:13 PM, Vania S. [vannyas@gmail.com](mailto:vannyas@gmail.com) wrote:

> Hi all,
> 
> I have 2 instances of elasticsearch in 2 different machines in different  
> networks (ip-A and ip-B). They have the same cluster name, but I don't want  
> them to replicate data between them, so I disabled all discovery  
> configurations by setting discovery.zen.ping.multicast.enabled to false in  
> both (the ideal situation would be they don't even know each other, making  
> them completely unaware of each other). I would like then to have another  
> instance of elasticsearch to function as a search load balancer, to allow  
> the search requests to enter through it and then search in the other 2  
> instances to fetch data from them and aggregate results.
> 
> Is this possible? I already tryed to configure the search load balancer  
> like this:
> 
> node.master: false  
> node.data: false  
> discovery.zen.ping.unicast.hosts: ["ip-A", "ip-B"]
> 
> but it only connects to one of them returning only results from the one it  
> is connected to.
> 
> Any suggestions?
> 
> Thanks,
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:29am UTC](https://discuss.elastic.co/t/configure-a-search-load-balancer-node/12512/4 "2017-07-06T02:29:43Z")

</div>


