# Allocating a shard: From where does it come?

**URL:** <https://discuss.elastic.co/t/allocating-a-shard-from-where-does-it-come/60300>\
**Category:** Elasticsearch\
**Created:** [September 12, 2016, 1:56pm UTC](https://discuss.elastic.co/t/allocating-a-shard-from-where-does-it-come/60300 "2016-09-12T13:56:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![klahnakoski](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/klahnakoski/32/3679_2.png) [@klahnakoski](https://discuss.elastic.co/u/klahnakoski)\
**Post date:** [September 12, 2016, 1:56pm UTC](https://discuss.elastic.co/t/allocating-a-shard-from-where-does-it-come/60300/1 "2016-09-12T13:56:57Z")

</div>

When I allocate a (replica) shard to a node, where does the data come from? Does it come from an existing shard in the same zone, or from the primary shard (probably not in the same zone).

Thank you

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [September 13, 2016, 7:27am UTC](https://discuss.elastic.co/t/allocating-a-shard-from-where-does-it-come/60300/2 "2016-09-13T07:27:22Z")

</div>

It comes from the matching primary shard, where ever it lives.

---

<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 5, 2017, 10:20pm UTC](https://discuss.elastic.co/t/allocating-a-shard-from-where-does-it-come/60300/3 "2017-07-05T22:20:51Z")

</div>

Closed on July 5, 2017, 10:20pm UTC


