# ES hangs up when sending too much index requests

**URL:** <https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121>\
**Category:** Elasticsearch\
**Created:** [March 26, 2012, 8:32am UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121 "2012-03-26T08:32:46Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ihor\_Hnedysh](https://avatars.discourse-cdn.com/v4/letter/i/58956e/32.png) [@Ihor\_Hnedysh](https://discuss.elastic.co/u/Ihor_Hnedysh)\
**Post date:** [March 26, 2012, 8:32am UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/1 "2012-03-26T08:32:46Z")

</div>

Good day,

we have faced with the ES handing by some reason, could you please take a look in it:  
\<nabble\_img src="Untitled.png" border="0"/\>

Elastic search configuration if the following:  
\<nabble\_img src="Untitled1.png" border="0"/\>

Can you comment this somehow? Do you need any additional data?

PS:

1. Problem reproduces sporadically with different requests
2. Log shows nothing

---

<div class="post-metadata">

**Author:** ![sborar](https://avatars.discourse-cdn.com/v4/letter/s/b4bc9f/32.png) [@sborar](https://discuss.elastic.co/u/sborar)\
**Post date:** [March 26, 2012, 6:04pm UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/2 "2012-03-26T18:04:59Z")

</div>

How many search requests are you sending ?

---

<div class="post-metadata">

**Author:** ![Ihor\_Hnedysh](https://avatars.discourse-cdn.com/v4/letter/i/58956e/32.png) [@Ihor\_Hnedysh](https://discuss.elastic.co/u/Ihor_Hnedysh)\
**Post date:** [March 26, 2012, 7:15pm UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/3 "2012-03-26T19:15:13Z")

</div>

differently. This time only 25 requests were sent (portionally. by 5 requests per time). All requests have similar structure. userId criteria only varies.

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [March 27, 2012, 6:48pm UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/4 "2012-03-27T18:48:26Z")

</div>

- Are the search request concurrent? If so, how many concurrent search  
requests are you sending?
- Are you opening a new socket on each request? The OS can stall opening  
new sockets if you do that excessively over time.
- How the machine stats on the two nodes? CPU, load?
- How much memory do you ahve allocated on the machine, how many  
CPUs/cores? How much memory have you allocated to ES?

On Mon, Mar 26, 2012 at 9:15 PM, Ihor Hnedysh [igorgnedish@gmail.com](mailto:igorgnedish@gmail.com) wrote:

> differently. This time only 25 requests were sent (portionally. by 5  
> requests  
> per time). All requests have similar structure. userId criteria only  
> varies.
> 
> --  
> View this message in context:  
> [http://elasticsearch-users.115913.n3.nabble.com/ES-hangs-up-when-sending-too-much-index-requests-tp3857628p3859097.html](http://elasticsearch-users.115913.n3.nabble.com/ES-hangs-up-when-sending-too-much-index-requests-tp3857628p3859097.html)  
> Sent from the Elasticsearch Users mailing list archive at [Nabble.com](http://Nabble.com).

---

<div class="post-metadata">

**Author:** ![Ihor\_Hnedysh](https://avatars.discourse-cdn.com/v4/letter/i/58956e/32.png) [@Ihor\_Hnedysh](https://discuss.elastic.co/u/Ihor_Hnedysh)\
**Post date:** [March 28, 2012, 9:18am UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/5 "2012-03-28T09:18:44Z")

</div>

> > Are the search request concurrent? If so, how many concurrent search requests are you sending?  
> > Yes. Requests are sent in parallel. Portionally. By five requests per portion. Total 25 requests.

> > Are you opening a new socket on each request? The OS can stall opening new sockets if you do that excessively over time.  
> > I'm not sure about your question since we're not using sockets directly. I will recheck it. But as far as I understand problem is that response did not came from Elasticsearch in the same time while it received it. I believe in it because request that was previously hanging is aborted right after Elasticsearch instance stopped. Also, frequency of problem reproducibility has been decreased after we have added additional data node.

> > How the machine stats on the two nodes? CPU, load?  
> > No CPU load. ProcessExplorer shows some cycles performed by Elasticsearch.

> > How much memory do you ahve allocated on the machine, how many CPUs/cores? How much memory Have you allocated to ES?  
> > I have standard JVM settings set. I did not tune them. PC is the following:  
> > RAM: 6GB  
> > CPU: 4 cores 3.2 GHz  
> > I have win7 on board but we have current problem reproduced not only on windows machine but on Ubuntu as well.

---

<div class="post-metadata">

**Author:** ![Ihor\_Hnedysh](https://avatars.discourse-cdn.com/v4/letter/i/58956e/32.png) [@Ihor\_Hnedysh](https://discuss.elastic.co/u/Ihor_Hnedysh)\
**Post date:** [March 30, 2012, 2:18pm UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/6 "2012-03-30T14:18:56Z")

</div>

up

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [March 31, 2012, 8:54pm UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/7 "2012-03-31T20:54:47Z")

</div>

Can you try and explain the problem again? How you run your tests, how many  
concurrent clients, what are you running.

On Wed, Mar 28, 2012 at 11:18 AM, Ihor Hnedysh [igorgnedish@gmail.com](mailto:igorgnedish@gmail.com)wrote:

> > > Are the search request concurrent? If so, how many concurrent search  
> > > requests are you sending?  
> > > Yes. Requests are sent in parallel. Portionally. By five requests per  
> > > portion. Total 25 requests.
> 
> > > Are you opening a new socket on each request? The OS can stall opening  
> > > new  
> > > sockets if you do that excessively over time.  
> > > I'm not sure about your question since we're not using sockets directly. I  
> > > will recheck it. But as far as I understand problem is that response did  
> > > not  
> > > came from Elasticsearch in the same time while it received it. I believe  
> > > in  
> > > it because request that was previously hanging is aborted right after  
> > > Elasticsearch instance stopped. Also, frequency of problem reproducibility  
> > > has been decreased after we have added additional data node.
> 
> > > How the machine stats on the two nodes? CPU, load?  
> > > No CPU load. ProcessExplorer shows some cycles performed by Elasticsearch.
> 
> > > How much memory do you ahve allocated on the machine, how many  
> > > CPUs/cores?  
> > > How much memory Have you allocated to ES?  
> > > I have standard JVM settings set. I did not tune them. PC is the following:  
> > > RAM: 6GB  
> > > CPU: 4 cores 3.2 GHz  
> > > I have win7 on board but we have current problem reproduced not only on  
> > > windows machine but on Ubuntu as well.
> 
> --  
> View this message in context:  
> [http://elasticsearch-users.115913.n3.nabble.com/ES-hangs-up-when-sending-too-much-index-requests-tp3857628p3863994.html](http://elasticsearch-users.115913.n3.nabble.com/ES-hangs-up-when-sending-too-much-index-requests-tp3857628p3863994.html)  
> Sent from the Elasticsearch Users mailing list archive at [Nabble.com](http://Nabble.com).

---

<div class="post-metadata">

**Author:** ![Alexander\_Gamanyuk](https://avatars.discourse-cdn.com/v4/letter/a/b4bc9f/32.png) [@Alexander\_Gamanyuk](https://discuss.elastic.co/u/Alexander_Gamanyuk)\
**Post date:** [April 3, 2012, 8:12am UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/8 "2012-04-03T08:12:02Z")

</div>

Ok, I will try to explain it in details.

We have about 120 tests. All the tests have some business logic and send different requests to ES. About 900 requests for all the tests.  
They are run by executing a batch file. We start the batch file with tests simultaneously 2 or more times. In average, every batch file sends about 4 requests per second. Since we started 2 ones we have about 7-8 requests per second.  
As a result we have about 3-7 hanged requests.  
I tested it in different configurations of ES, [detailed raw result are here](https://docs.google.com/spreadsheet/ccc?key=0AqIOcq3V0d2hdFFjb1FpUDkxNW5UQVBvdXNNd0szaEE)

Note, using tests is just an easy way of reproducing of the problem. The problem exist in a real application as well.  
Hope it helps.

---

<div class="post-metadata">

**Author:** ![Alexander\_Gamanyuk](https://avatars.discourse-cdn.com/v4/letter/a/b4bc9f/32.png) [@Alexander\_Gamanyuk](https://discuss.elastic.co/u/Alexander_Gamanyuk)\
**Post date:** [April 11, 2012, 10:07am UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/9 "2012-04-11T10:07:50Z")

</div>

We're using version 0.18.4, but the problem is reproducing on 0.19.2 as well.

---

<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, 3:32am UTC](https://discuss.elastic.co/t/es-hangs-up-when-sending-too-much-index-requests/7121/10 "2017-07-06T03:32:58Z")

</div>


