# Too many indices

**URL:** <https://discuss.elastic.co/t/too-many-indices/172679>\
**Category:** Elasticsearch\
**Created:** [March 17, 2019, 12:43pm UTC](https://discuss.elastic.co/t/too-many-indices/172679 "2019-03-17T12:43:16Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![facek1ck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/facek1ck/32/42187_2.png) [@facek1ck](https://discuss.elastic.co/u/facek1ck)\
**Post date:** [March 17, 2019, 12:43pm UTC](https://discuss.elastic.co/t/too-many-indices/172679/1 "2019-03-17T12:43:16Z")

</div>

Hello everyone.  
I am new to elasticsearch and don't really understand the documentation for nodes and shards and all of that stuff. My problem is that I have around 2-3k indices and when I try to create an index pattern in kibana or basically whenever I try to do anything in kibana it just freezes and then crashes, giving me an error 503 "all shards failed". After researching a lot I think the problem is that I have to many shards(?)  
As I said I just don't understand it that well.  
I hope someone can help me.

---

<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:** [March 17, 2019, 12:56pm UTC](https://discuss.elastic.co/t/too-many-indices/172679/2 "2019-03-17T12:56:01Z")

</div>

It sounds like that may very well be the case. I would recommend reading [this blog post](https://www.elastic.co/blog/how-many-shards-should-i-have-in-my-elasticsearch-cluster) about shards and sharding for guidance.

---

<div class="post-metadata">

**Author:** ![facek1ck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/facek1ck/32/42187_2.png) [@facek1ck](https://discuss.elastic.co/u/facek1ck)\
**Post date:** [March 17, 2019, 1:19pm UTC](https://discuss.elastic.co/t/too-many-indices/172679/3 "2019-03-17T13:19:31Z")

</div>

Okay so I just read through all of that but I still don't get how I can have 2000 indices and not have performance issues. I need an index for every customer and there is just one document every day per customer. So I'm guessing I don't need 5 shards + replicas for each index (?)  
And if so, how do I tell elasticsearch to use less shards per index?  
I'm running elasticsearch in a docker container by the way.

---

<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:** [March 17, 2019, 2:17pm UTC](https://discuss.elastic.co/t/too-many-indices/172679/4 "2019-03-17T14:17:18Z")

</div>

Having an index per customer tends to scale badly. Why do you not have the customers share an index and add a field specifying the user that you can filter on?

---

<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:** [April 14, 2019, 2:17pm UTC](https://discuss.elastic.co/t/too-many-indices/172679/5 "2019-04-14T14:17:20Z")

</div>

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