# Shards allocation across nodes

**URL:** <https://discuss.elastic.co/t/shards-allocation-across-nodes/200138>\
**Category:** Elasticsearch\
**Created:** [September 19, 2019, 7:34am UTC](https://discuss.elastic.co/t/shards-allocation-across-nodes/200138 "2019-09-19T07:34:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ravi\_gajareddy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ravi_gajareddy/32/54483_2.png) [@ravi\_gajareddy](https://discuss.elastic.co/u/ravi_gajareddy)\
**Post date:** [September 19, 2019, 7:34am UTC](https://discuss.elastic.co/t/shards-allocation-across-nodes/200138/1 "2019-09-19T07:34:43Z")

</div>

How shards are allocated across nodes.If I have 2 nodes where index contains primary shards : 3 and Replica shards : 2. My index is showing yellow color. Is it allocates all primary shards in 1st node and all replica shards in 2nd node.

---

<div class="post-metadata">

**Author:** ![cknoell](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cknoell/32/47353_2.png) [@cknoell](https://discuss.elastic.co/u/cknoell)\
**Post date:** [September 19, 2019, 9:18am UTC](https://discuss.elastic.co/t/shards-allocation-across-nodes/200138/2 "2019-09-19T09:18:15Z")

</div>

Have you read thru this -\> [https://www.elastic.co/guide/en/elasticsearch/reference/current/shards-allocation.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/shards-allocation.html) ?

---

<div class="post-metadata">

**Author:** ![ravi\_gajareddy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ravi_gajareddy/32/54483_2.png) [@ravi\_gajareddy](https://discuss.elastic.co/u/ravi_gajareddy)\
**Post date:** [September 19, 2019, 9:33am UTC](https://discuss.elastic.co/t/shards-allocation-across-nodes/200138/3 "2019-09-19T09:33:47Z")

</div>

thanks for the link but the link explains about dynamic settings, I want to know how elastic search allocate shards by default

---

<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:** [October 17, 2019, 9:34am UTC](https://discuss.elastic.co/t/shards-allocation-across-nodes/200138/4 "2019-10-17T09:34:11Z")

</div>

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