# Detective wanted: Green cluster but query timeout unless changing preference to local

**URL:** <https://discuss.elastic.co/t/detective-wanted-green-cluster-but-query-timeout-unless-changing-preference-to-local/17863>\
**Category:** Elasticsearch\
**Created:** [June 2, 2014, 6:22pm UTC](https://discuss.elastic.co/t/detective-wanted-green-cluster-but-query-timeout-unless-changing-preference-to-local/17863 "2014-06-02T18:22:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![arthurx](https://avatars.discourse-cdn.com/v4/letter/a/ecd19e/32.png) [@arthurx](https://discuss.elastic.co/u/arthurx)\
**Post date:** [June 2, 2014, 6:22pm UTC](https://discuss.elastic.co/t/detective-wanted-green-cluster-but-query-timeout-unless-changing-preference-to-local/17863/1 "2014-06-02T18:22:46Z")

</div>

I had debugging this problem for so long time now. I tweaked every relevant  
setting but just cannot get it to work. I really hope someone with  
knowledge about Elasticsearch networking can give me some help.

So I got two machines in the same data-center, but communicate to each  
other by public ip. (network.publish\_host is set)  
The symptoms are:  
1: Cluster health is green showing 2 nodes  
2: When the slave node initially started, all queries are fine. After some  
time, query would not work unless adding "preference=\_local". This is true  
for HTTP curl for both machine.  
3: When I shut down the slave node, soon the master node would work fine  
without the "\_local" suffix.

No special error is shown.  
Please feel free to share any ideas you have about this case.

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/0a2c60d6-56d5-4d8d-8549-3f61aaa46cd2%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/0a2c60d6-56d5-4d8d-8549-3f61aaa46cd2%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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 16, 2014, 11:44am UTC](https://discuss.elastic.co/t/detective-wanted-green-cluster-but-query-timeout-unless-changing-preference-to-local/17863/2 "2014-06-16T11:44:33Z")

</div>

Hey,

you should check your logfiles on each of the nodes. Maybe they  
disconnected from each other (and reconnect all the time), so that you get  
problems when you execute your requests round robin. Using curl from one  
node to another does not show any problems? They are reachable all the time  
(at low latency)?

--Alex

On Mon, Jun 2, 2014 at 8:22 PM, arthurX [fc28222@gmail.com](mailto:fc28222@gmail.com) wrote:

> I had debugging this problem for so long time now. I tweaked every  
> relevant setting but just cannot get it to work. I really hope someone with  
> knowledge about Elasticsearch networking can give me some help.
> 
> So I got two machines in the same data-center, but communicate to each  
> other by public ip. (network.publish\_host is set)  
> The symptoms are:  
> 1: Cluster health is green showing 2 nodes  
> 2: When the slave node initially started, all queries are fine. After some  
> time, query would not work unless adding "preference=\_local". This is true  
> for HTTP curl for both machine.  
> 3: When I shut down the slave node, soon the master node would work fine  
> without the "\_local" suffix.
> 
> No special error is shown.  
> Please feel free to share any ideas you have about this case.
> 
> --  
> 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).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/0a2c60d6-56d5-4d8d-8549-3f61aaa46cd2%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/0a2c60d6-56d5-4d8d-8549-3f61aaa46cd2%40googlegroups.com)  
> [https://groups.google.com/d/msgid/elasticsearch/0a2c60d6-56d5-4d8d-8549-3f61aaa46cd2%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/0a2c60d6-56d5-4d8d-8549-3f61aaa46cd2%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAGCwEM\_YeNPm3dOwEwSHcqGwjxx-dq18KVgoF8Ayhpkv26w3gw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAGCwEM_YeNPm3dOwEwSHcqGwjxx-dq18KVgoF8Ayhpkv26w3gw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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, 1:22am UTC](https://discuss.elastic.co/t/detective-wanted-green-cluster-but-query-timeout-unless-changing-preference-to-local/17863/3 "2017-07-06T01:22:16Z")

</div>


