# How to display the maximum number of shards allowed per node?

**URL:** <https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308>\
**Category:** Elasticsearch\
**Created:** [January 17, 2024, 9:11pm UTC](https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308 "2024-01-17T21:11:57Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![mpniel](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mpniel/32/113170_2.png) [@mpniel](https://discuss.elastic.co/u/mpniel)\
**Post date:** [January 17, 2024, 9:11pm UTC](https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308/1 "2024-01-17T21:11:57Z")

</div>

how to display the maximum number of shards allowed per node?

---

<div class="post-metadata">

**Author:** ![yago82](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yago82/32/97755_2.png) [@yago82](https://discuss.elastic.co/u/yago82)\
**Post date:** [January 17, 2024, 9:19pm UTC](https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308/2 "2024-01-17T21:19:23Z")

</div>

> [@mpniel](#):
>
> how to display the maximum number of shards allowed per node?

Hi,

You can check the maximum number of shards allowed per node by running the following command:

```auto
GET _cluster/settings?include_defaults=true&filter_path=**.cluster.routing.allocation.total_shards_per_node

```

Regards

---

<div class="post-metadata">

**Author:** ![mpniel](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mpniel/32/113170_2.png) [@mpniel](https://discuss.elastic.co/u/mpniel)\
**Post date:** [January 18, 2024, 5:31pm UTC](https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308/3 "2024-01-18T17:31:55Z")

</div>

Ok I got -1 it means unlimited?  
If correct then why I see in \_cat/allocation no more than 1000 shards per node?

---

<div class="post-metadata">

**Author:** ![yago82](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yago82/32/97755_2.png) [@yago82](https://discuss.elastic.co/u/yago82)\
**Post date:** [January 19, 2024, 7:43am UTC](https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308/4 "2024-01-19T07:43:18Z")

</div>

Hi,

Defaults to `-1` (unlimited).

cluster.max\_shards\_per\_node  
Defaults to `1000`

> **[Total shards per node | Elasticsearch Guide \[8.12\] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/allocation-total-shards.html#allocation-total-shards)**

---

<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:** [January 19, 2024, 7:54am UTC](https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308/5 "2024-01-19T07:54:34Z")

</div>

> [@mpniel](#):
>
> If correct then why I see in \_cat/allocation no more than 1000 shards per node?

The limit is 1000 shards per node. You can override this, but that is generally a bad idea. You would just be postponing the issue and may end up in a situation where the issue can no longer be corrected, resulting in an inoperable cluster and data loss. If you are hitting this limit I would recommend you instead read [this blog post](https://www.elastic.co/blog/how-many-shards-should-i-have-in-my-elasticsearch-cluster) and [this guide](https://opster.com/guides/elasticsearch/capacity-planning/elasticsearch-oversharding/). In order to properly address this issue you can follow [this guide](https://opster.com/guides/elasticsearch/capacity-planning/elasticsearch-reduce-shards/).

---

<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:** [February 16, 2024, 7:55am UTC](https://discuss.elastic.co/t/how-to-display-the-maximum-number-of-shards-allowed-per-node/351308/6 "2024-02-16T07:55:21Z")

</div>

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