Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Elasticsearch reindex tasks 404ing

I'm running reindex calls with wait_for_completion=false at a remote server.

Its simple:

Start reindex, get task id
while(task not finished) wait(someTime)

The while loop contains a GET host/_tasks/ which allows me to check it the task is completed.

When running locally, everything is fine. I can get the task info before and after it finished.

When runninng remote, I'm getting 404 when trying to get the task.

 ...
    "type" : "resource_not_found_exception",
    "reason" : "task [7n71h1QXTluH0FakbZULgw:8525570] isn't running and hasn't stored its results"
  },
  "status" : 404

Here: https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-reindex.html#docs-reindex-task-api it says that we should delete the task when its not needed anymore, so I expect it shouldn't be deleting automatically when finished (as it doesn't when running locally)

I don't have direct access to the server. I can only ask someone else to run the code and send me the log.

Any ideas on why this might be happening? Or what to try

like image 208
galmeida Avatar asked Jan 26 '26 11:01

galmeida


1 Answers

An elasticsearch consultant stated that, in my specific situation, the elasticsearch circuit beaker was terminating and deleting the task due to memory shortage. He reconfigured the node and that fixed the problem.

like image 157
galmeida Avatar answered Jan 29 '26 04:01

galmeida



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!