# Index then query cost 20 minutes more with half billion rows

**URL:** https://discuss.elastic.co/t/index-then-query-cost-20-minutes-more-with-half-billion-rows/20279
**Category:** Elasticsearch
**Created:** [October 16, 2014, 9:37am UTC](https://discuss.elastic.co/t/index-then-query-cost-20-minutes-more-with-half-billion-rows/20279 "2014-10-16T09:37:50Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![jolly123](https://avatars.discourse-cdn.com/v4/letter/j/9fc29f/32.png) [@jolly123](https://discuss.elastic.co/u/jolly123)
#### Post date: [October 16, 2014, 9:37am UTC](https://discuss.elastic.co/t/index-then-query-cost-20-minutes-more-with-half-billion-rows/20279/1 "2014-10-16T09:37:50Z")

</div>

Dear ,

I just use es 1.3.1, memory 32G of 128G, 10 shards, 1 replicas, half billion rows for only one index, which occupy 80G disk,

if I add a new document into the index, can search it after 20 minutes later,, I just set the index.refresh\_interval: 2s ,when there is only thousands data, can search it quickly.  
So many lazy time can not be acceptable for us, anyone can give me the solution?

Thanks

---

<div class="post-metadata">

### Author: ![jolly123](https://avatars.discourse-cdn.com/v4/letter/j/9fc29f/32.png) [@jolly123](https://discuss.elastic.co/u/jolly123)
#### Post date: [October 17, 2014, 8:55am UTC](https://discuss.elastic.co/t/index-then-query-cost-20-minutes-more-with-half-billion-rows/20279/2 "2014-10-17T08:55:39Z")

</div>

I just test it ,when there is only thousands data, the issue still,  
I add one record with curl, can get data with curl -XGET method, but can't  
find it in head plugin web site, also can't get it with java client.  
before that I use bulk insert data, when bulk ,from log I find that es set refresh\_interval to -1,  
does it caused? how can I reset it to 2s after bulk?

anybody can help me ? thanks a lot....

---

<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, 12:55am UTC](https://discuss.elastic.co/t/index-then-query-cost-20-minutes-more-with-half-billion-rows/20279/3 "2017-07-06T00:55:33Z")

</div>


