# Allocation Failed

**URL:** <https://discuss.elastic.co/t/allocation-failed/342167>\
**Category:** Elasticsearch\
**Created:** [September 2, 2023, 1:12pm UTC](https://discuss.elastic.co/t/allocation-failed/342167 "2023-09-02T13:12:59Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![njain213](https://avatars.discourse-cdn.com/v4/letter/n/74df32/32.png) [@njain213](https://discuss.elastic.co/u/njain213)\
**Post date:** [September 2, 2023, 1:12pm UTC](https://discuss.elastic.co/t/allocation-failed/342167/1 "2023-09-02T13:12:59Z")

</div>

Hello Team,

One of my index is showing below error. I have created new shard where new data is going now but how to assign old index back to node.

"unassigned\_info" : {  
"reason" : "ALLOCATION\_FAILED",  
"at" : "2023-09-01T18:06:49.256Z",  
"failed\_allocation\_attempts" : 1,  
"details" : "failed shard on node [OZyZPGCJS6SV9tj1JM9ZDw]: shard failure, reason [no-op origin[PRIMARY] seq#[2147483524] failed at document level], failure IllegalArgumentException[number of documents in the index cannot exceed 2147483519]",  
"last\_allocation\_status" : "no\_valid\_shard\_copy"  
},

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [September 2, 2023, 2:07pm UTC](https://discuss.elastic.co/t/allocation-failed/342167/2 "2023-09-02T14:07:38Z")

</div>

What version are you using?

---

<div class="post-metadata">

**Author:** ![njain213](https://avatars.discourse-cdn.com/v4/letter/n/74df32/32.png) [@njain213](https://discuss.elastic.co/u/njain213)\
**Post date:** [September 4, 2023, 5:07am UTC](https://discuss.elastic.co/t/allocation-failed/342167/3 "2023-09-04T05:07:11Z")

</div>

7.9.3

---

<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:** [September 4, 2023, 6:05am UTC](https://discuss.elastic.co/t/allocation-failed/342167/4 "2023-09-04T06:05:58Z")

</div>

I suspect you have hit [the bug described in this thread](https://discuss.elastic.co/t/when-the-number-of-documents-exceeds-2-billion-the-index-status-becomes-red/341461) as you are running a very old version that has been EOL a long time. As mentioned in the thread you probably need to restore that index from a snapshot to recover it. Once that is done you should look to upgrade.

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [September 4, 2023, 6:09am UTC](https://discuss.elastic.co/t/allocation-failed/342167/5 "2023-09-04T06:09:30Z")

</div>

Yes that's right, this bug was [fixed](https://github.com/elastic/elasticsearch/pull/63273) almost 3 years ago.

---

<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 2, 2023, 6:10am UTC](https://discuss.elastic.co/t/allocation-failed/342167/6 "2023-10-02T06:10:27Z")

</div>

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