# Reindex big index

**URL:** <https://discuss.elastic.co/t/reindex-big-index/83047>\
**Category:** Elasticsearch\
**Created:** [April 20, 2017, 11:56am UTC](https://discuss.elastic.co/t/reindex-big-index/83047 "2017-04-20T11:56:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jackiekhuu\_work](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jackiekhuu_work/32/6452_2.png) [@jackiekhuu\_work](https://discuss.elastic.co/u/jackiekhuu_work)\
**Post date:** [April 20, 2017, 11:56am UTC](https://discuss.elastic.co/t/reindex-big-index/83047/1 "2017-04-20T11:56:26Z")

</div>

I would like to reindex a very big index.

When I run reindex API with elasticsearchjs client I will receive the requestTimeout error, or Gateway timeout error.  
It's ok because the reindex process is still running in Elastic server. However, what I want to do is after the reindex finish with full data, I will execute another task.  
The question is how can I know the reindex succeeded to run other task?  
What is the best practice for this use case?  
Please help!

---

<div class="post-metadata">

**Author:** ![ultimate.duwal](https://avatars.discourse-cdn.com/v4/letter/u/2acd7d/32.png) [@ultimate.duwal](https://discuss.elastic.co/u/ultimate.duwal)\
**Post date:** [April 20, 2017, 12:04pm UTC](https://discuss.elastic.co/t/reindex-big-index/83047/2 "2017-04-20T12:04:55Z")

</div>

You can use POST [http://xxx.xxx.xxx.xxx:9200/\_reindex?wait\_for\_completion=true](http://xxx.xxx.xxx.xxx:9200/_reindex?wait_for_completion=true) in the url so that the query for reindex wait to return the response until completion.

Or you can check  
GET [http://xxx.xxx.xxx.xxx:9200/\_tasks/?pretty&detailed=true&actions=\*reindex](http://xxx.xxx.xxx.xxx:9200/_tasks/?pretty&detailed=true&actions=*reindex)  
in an interval and see if the response is not **nodes:{}** empty.

---

<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:** [May 18, 2017, 12:06pm UTC](https://discuss.elastic.co/t/reindex-big-index/83047/3 "2017-05-18T12:06:40Z")

</div>

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