# Bulk inserts bring down query performance

**URL:** <https://discuss.elastic.co/t/bulk-inserts-bring-down-query-performance/255248>\
**Category:** Elasticsearch\
**Created:** [November 12, 2020, 5:11pm UTC](https://discuss.elastic.co/t/bulk-inserts-bring-down-query-performance/255248 "2020-11-12T17:11:42Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eric\_Bowden](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/eric_bowden/32/60252_2.png) [@Eric\_Bowden](https://discuss.elastic.co/u/Eric_Bowden)\
**Post date:** [November 12, 2020, 5:11pm UTC](https://discuss.elastic.co/t/bulk-inserts-bring-down-query-performance/255248/1 "2020-11-12T17:11:42Z")

</div>

Our application occasionally performs large volumes of index insert/updates, it could be in the range of 10,000. To speed this up, we're allocating the upload/insert work across 10 threads, running continuously until all of the inserts/updates are complete.

We're finding that the inserts/updates are having a substantial impact on query performance, essentially taking query capability offline (too slow to be usable).

We're running in [elastic.co](http://elastic.co), IO Optimized, 3 zones, 1 node per zone, 8GB per node.

If we're finding that query performance is fine, except when performing bulk update/insert, which of our environment paramters should we increase? more nods, more ram, something else?

Appreciate any specific or general guidance.

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [November 12, 2020, 5:23pm UTC](https://discuss.elastic.co/t/bulk-inserts-bring-down-query-performance/255248/2 "2020-11-12T17:23:58Z")

</div>

Indexing can be CPU as well as disk I/O intense. It may be worth looking at monitoring data to see if you can see what the limiting factor is. I believe CPU resources are allocated proportional to the size of the node so I would recommend increasing the size of the nodes and see what impact this has. You can also reduce the concurrency and maybe also turn off refreshing while you bulk upload and then turn it back on once you are done.

---

<div class="post-metadata">

**Author:** ![Eric\_Bowden](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/eric_bowden/32/60252_2.png) [@Eric\_Bowden](https://discuss.elastic.co/u/Eric_Bowden)\
**Post date:** [November 12, 2020, 5:39pm UTC](https://discuss.elastic.co/t/bulk-inserts-bring-down-query-performance/255248/3 "2020-11-12T17:39:00Z")

</div>

Thanks @Christian_Dahlqvist. We have tried disabling refreshes, this didn't help. The idea that CPU resources are allocated proportional to the size of the node sounds promising. But... I don't see this documented? We can give it a try, in any case.

---

<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:** [December 10, 2020, 5:39pm UTC](https://discuss.elastic.co/t/bulk-inserts-bring-down-query-performance/255248/4 "2020-12-10T17:39:03Z")

</div>

Closed on December 10, 2020, 5:39pm UTC

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
