Creating multiple snapshots one after other immediatly

Hi All.......

Here i am trying to create two snapshots at a time from Kibana devtool
here are my commands looks like

PUT /_snapshot/repo/dev_1?wait_for_completion=true
PUT /_snapshot/repo/dev_2?wait_for_completion=true

here first i run the dec_1 snapshot after that i tried running second snapshot dev_2
but it throws me an error like this

{
 "error": {
   "root_cause": [
     {
       "type": "concurrent_snapshot_execution_exception",
       "reason": "[repo:dev_2]a snapshot is already running"
     }
   ],
   "type": "concurrent_snapshot_execution_exception",
   "reason": "[repo:dev_2]a snapshot is already running"
 },
 "status": 503
}

Will this test case accepts elasticsearch?
or i need to wait untill the first snapshot process to be fineshed

Thank You.

Hi,

I've stumbled upon a similar issue when using the Elasticsearch Snapshot API:

It seems like an internal limitation and a lack of queue implementation.
Hopefully, there is some kind of workaround.

There can only be one snapshot taken at a time. This is because we do things under the hood like stop merging of segments to ensure consistency.

As our cluster holds data for different users, retentions, and replica SLAs, we need to execute several snapshot tasks every day.

I understand there is a technical limitation for actually running two snapshots concurrently, but I think it would be a good idea to have elasticsearch add snapshots requests to a queue, automatically executing each snapshot as the previous finished running.

Otherwise, we are left with the same limitation but having to manage a queueing mechanism for elasticsearch, tracking what is the current snapshot, whether it has finished and only then run call the API for the next snapshot task. This is a lot of overhead for a relatively simple use case :sweat:

#feature_request

If you'd like to see this then please do raise a feature request on Github https://github.com/elastic/elasticsearch/issues :smiley:

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