0

I have around 5 Million items in my index v1. I created a new index v2 with slight changes. I am trying to reindex all the items in v1 --> v2.

curl -XPOST 'localhost:9200/_reindex?pretty' -H 'Content-Type: application/json' -d'
{
  "source": {
    "index": "twitter"
  },
  "dest": {
    "index": "new_twitter"
  }
}
'

When I tried this, only 1.6 Million items are re indexed. The operation times out. How do I work around it ?

Hexy
  • 828
  • 14
  • 24

1 Answers1

2

You should use the wait_for_completion=false parameter mentioned in the reindex docs. It allows you to run the reindex request in the background without your HTTP client being forced to wait and block and potentially time out.

alr
  • 1,744
  • 1
  • 10
  • 11