1

am trying to reindex in opensearch for large data sets which is around 5gb, since the default timeout of opensearch is 30s , how do we increase the timeout to 5m or 10m

POST _reindex
{
  "source": {
    "index": "a"
  },
  "dest": {
    "index": "b"
  }
}


since using verion 2.3.0 , "timeout" and request_timeout is not avaliable. any solutions how can increase the time out.

GET _cluster/settings in cluster setting did not find any timeout. 
not able to create new template with timeout.

1 Answers1

0

Reindex will continue to run in the background even if it seems to be a timeout. You can check the reindex currently running in the background with the following command.

GET _tasks?actions=*reindex

You can prevent seeing the timeout error with

POST _reindex?wait_for_completion=false

check your index sizes and docs.count to understand what is happening.

GET _cat/indices?v
Musab Dogan
  • 1,811
  • 1
  • 6
  • 8
  • and also one more doubt, if do the Reindex on top of existing index, weather it will replace the data or it will add data to existing data itself? – Keerthi Hassan May 03 '23 at 15:22
  • Reindex uses `_id` to generate documents in the destination index. So it will replace the existing data. You can check `GET _cat/indices?v` and check the *deleted.docs* count. Every update/delete operation increase that number. – Musab Dogan May 04 '23 at 06:46