# Reindex 2.4 to 5.6

**URL:** <https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642>\
**Category:** Elasticsearch\
**Created:** [January 28, 2022, 12:54am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642 "2022-01-28T00:54:51Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![mario12](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mario12/32/29324_2.png) [@mario12](https://discuss.elastic.co/u/mario12)\
**Post date:** [January 28, 2022, 12:54am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/1 "2022-01-28T00:54:51Z")

</div>

We are in the process of re-indexing 2.4 to 5.6. During the re-indexing process the application is able to perform inserts/updates/delete operation to 2.4. So, we are planning to re-index again to copy the missing documents and replicate update/delete operation. What is the re-index option we need to use to achieve this?

---

<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 28, 2022, 1:44am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/2 "2022-01-28T01:44:41Z")

</div>

Reindex runs based on the data that is available when it starts and will not catch subsequent changes or additions. There is no automatic/built-in way to catch up changes made since the last reindex so you need to create a query based on your data, e.g. last modified timestamp, to run a subsequent reindex to catch up.

I suspect it will be very hard to do this without any downtime.

---

<div class="post-metadata">

**Author:** ![mario12](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mario12/32/29324_2.png) [@mario12](https://discuss.elastic.co/u/mario12)\
**Post date:** [January 28, 2022, 2:35am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/3 "2022-01-28T02:35:55Z")

</div>

How about the following steps?

1. Stop the apps
2. Reindex from 2.4 to 5.6.
3. Point the apps to 5.6 indices by changing the aliases.
4. Bring up the apps
5. Reindex again from 2.4 to 5.6 to catch up the inserts/updates/deletes with the following options:

POST \_reindex  
{  
"source": {  
"index": "ES2.4Indices"  
},  
"dest": {  
"index": "ES5.6Indices",  
"version\_type": "external"  
}  
}

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [January 28, 2022, 5:46am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/4 "2022-01-28T05:46:56Z")

</div>

I'd recommend reindexing directly to 7.16.  
It's a waste of time IMO to reindex to something which is not supported anymore and did not benefit from all the security patches.

You could use the reindex from remote API for this.

---

<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:** [January 28, 2022, 6:23am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/5 "2022-01-28T06:23:13Z")

</div>

I have to agree with David, going from one unsupported version to another doesn't make the process easier.

---

<div class="post-metadata">

**Author:** ![mario12](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mario12/32/29324_2.png) [@mario12](https://discuss.elastic.co/u/mario12)\
**Post date:** [January 28, 2022, 6:28am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/6 "2022-01-28T06:28:01Z")

</div>

@dadoonet @warkolm Thanks for your response. We host PB's of data in Elasticsearch. So, we can't do remote re-indexing due to the volume of data. This is the reason we are planning to upgrade to ES 5.6 at this moment. Once all indices are in 5.6 we are planning to upgrade to 6.8 and eventually 7.x. Can you please let me know if the steps mentioned in the previous message will work?

---

<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:** [January 28, 2022, 6:40am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/7 "2022-01-28T06:40:04Z")

</div>

It looks ok, yes.

However once you cross into 6.X and 7.X you will have mapping changes you need to work on.

---

<div class="post-metadata">

**Author:** ![mario12](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mario12/32/29324_2.png) [@mario12](https://discuss.elastic.co/u/mario12)\
**Post date:** [January 28, 2022, 7:17am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/8 "2022-01-28T07:17:19Z")

</div>

ok. Thank you @warkolm @dadoonet @Christian_Dahlqvist

---

<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 25, 2022, 7:18am UTC](https://discuss.elastic.co/t/reindex-2-4-to-5-6/295642/9 "2022-02-25T07:18:07Z")

</div>

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