# Open index on restore snapshot action

**URL:** <https://discuss.elastic.co/t/open-index-on-restore-snapshot-action/226384>\
**Category:** Elasticsearch\
**Created:** [April 3, 2020, 10:12am UTC](https://discuss.elastic.co/t/open-index-on-restore-snapshot-action/226384 "2020-04-03T10:12:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Wallie](https://avatars.discourse-cdn.com/v4/letter/w/54ee81/32.png) [@Wallie](https://discuss.elastic.co/u/Wallie)\
**Post date:** [April 3, 2020, 10:12am UTC](https://discuss.elastic.co/t/open-index-on-restore-snapshot-action/226384/1 "2020-04-03T10:12:49Z")

</div>

Am trying to move our ELK stack to a different machine to verify backup/restore procedure. A snapshot has been created on machine A, after creating a Repository.  
Moved full repository directory to machine B, added the repository on that machine.  
Snapshots created on machine A are detected on machine B, so tried to load the snapshot on machine B using  
`POST /_snapshot/virt06/snapshot-number-one/_restore`  
When performing the restore action, it fails on the fact one of the indexes is in use:

```auto
 "error" : {
   "root_cause" : [
     {
       "type" : "snapshot_restore_exception",
       "reason" : "[virt06:snapshot-number-one/273qaO3DRx2HdERZTzvmEw] cannot restore index [.security-7] because an open index with same name already exists in the cluster. Either close or delete the existing index or restore the index under a different name by providing a rename pattern and replacement name"
     }
   ],
   "type" : "snapshot_restore_exception",
   "reason" : "[virt06:snapshot-number-one/273qaO3DRx2HdERZTzvmEw] cannot restore index [.security-7] because an open index with same name already exists in the cluster. Either close or delete the existing index or restore the index under a different name by providing a rename pattern and replacement name"
 },
 "status" : 500
}

```

Closing the index results in a non functional ELK cluster.

Any ideas how to properly perform a restore action?

---

<div class="post-metadata">

**Author:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [April 3, 2020, 1:52pm UTC](https://discuss.elastic.co/t/open-index-on-restore-snapshot-action/226384/2 "2020-04-03T13:52:58Z")

</div>

You may want to specify the indices you want to restore (that would be your indices of your application, not the security specific ones).

See [https://www.elastic.co/guide/en/elasticsearch/reference/7.6/snapshots-restore-snapshot.html](https://www.elastic.co/guide/en/elasticsearch/reference/7.6/snapshots-restore-snapshot.html)

---

<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 1, 2020, 1:52pm UTC](https://discuss.elastic.co/t/open-index-on-restore-snapshot-action/226384/3 "2020-05-01T13:52:59Z")

</div>

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