# Nfs repository and restore elastic snapshot

**URL:** <https://forum.opensearch.org/t/nfs-repository-and-restore-elastic-snapshot/17537>\
**Category:** OpenSearch\
**Created:** [January 22, 2024, 7:42pm UTC](https://forum.opensearch.org/t/nfs-repository-and-restore-elastic-snapshot/17537 "2024-01-22T19:42:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![maxim](https://avatars.discourse-cdn.com/v4/letter/m/ba9def/32.png) [@maxim](https://forum.opensearch.org/u/maxim)\
**Post date:** [January 22, 2024, 7:42pm UTC](https://forum.opensearch.org/t/nfs-repository-and-restore-elastic-snapshot/17537/1 "2024-01-22T19:42:50Z")

</div>

**Versions** (relevant - OpenSearch/Dashboard/Server OS/Browser):  
opensearch v 2.8.0  
elasticsearch v 8.10.3

**Configuration** :  
elk \ os repo params:

```auto
path.repo: ["/var/lib/snapshots"]

```

**problem** :  
hello! Tell me please.  
I created nfs and connected it to the elk cluster, created a snapshot with a couple of indexes.  
connected the same nfs to the opensearch cluster. I’m now faced with two problems

```auto
PUT /_snapshot/my-repo
{
  "type": "fs",
  "settings": {
    "location": "/var/lib/snapshots"
  }
}

```

output

```auto
{
  "acknowledged": true
}

```

now when I go to opensearch dashboards in the repositories tab there is an error

```auto
{"error":{"root_cause":[{"type":"parsing_exception","reason":"Failed to parse object: unknown field [uuid] found","line":1,"col":25}],"type":"repository_exception","reason":"[snapshots] Unexpected exception when loading repository data","caused_by":{"type":"parsing_exception","reason":"Failed to parse object: unknown field [uuid] found","line":1,"col":25}},"status":500}

```

now when I try to load indexes from a snapshot I get an error

```auto
POST /_snapshot/my-repo/snapshot_1/_restore
output response:
{
  "error": {
    "root_cause": [
      {
        "type": "parsing_exception",
        "reason": "Failed to parse object: unknown field [uuid] found",
        "line": 1,
        "col": 25
      }
    ],
    "type": "repository_exception",
    "reason": "[my-repo] Unexpected exception when loading repository data",
    "caused_by": {
      "type": "parsing_exception",
      "reason": "Failed to parse object: unknown field [uuid] found",
      "line": 1,
      "col": 25
    }
  },
  "status": 500
}

```

please tell me what is my mistake

---

<div class="post-metadata">

**Author:** ![maxim](https://avatars.discourse-cdn.com/v4/letter/m/ba9def/32.png) [@maxim](https://forum.opensearch.org/u/maxim)\
**Post date:** [January 23, 2024, 7:41am UTC](https://forum.opensearch.org/t/nfs-repository-and-restore-elastic-snapshot/17537/2 "2024-01-23T07:41:20Z")

</div>

I realized that it will not be possible to transfer indexes from these versions, are there any other ways?

---

<div class="post-metadata">

**Author:** ![pablo](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/pablo/32/10363_2.png) [@pablo](https://forum.opensearch.org/u/pablo)\
**Post date:** [January 23, 2024, 1:36pm UTC](https://forum.opensearch.org/t/nfs-repository-and-restore-elastic-snapshot/17537/3 "2024-01-23T13:36:01Z")

</div>

@maxim According to the documentation you can snapshot and restore with OpenSearch indices of ES 6.x and 7.x

> **[Using snapshots to migrate data](https://opensearch.org/docs/latest/upgrade-to/snapshot-migrate/)**
>
> Using snapshots to migrate data

When your data are at version 8.x then the only option I’m aware of would be streaming the data between the clusters using i.e. Logtash OSS with OpenSearch output plugin.

> **[Migrating from Elasticsearch OSS to OpenSearch](https://opensearch.org/docs/latest/upgrade-to/upgrade-to/)**
>
> Migrating from Elasticsearch OSS to OpenSearch

> To migrate a post-fork version of Elasticsearch (7.11+) to OpenSearch, you can use Logstash. You’ll need to employ the Elasticsearch input plugin within Logstash to extract data from the Elasticsearch cluster, and the Logstash Output OpenSearch plugin to write the data to the OpenSearch 2.x cluster. We suggest using Logstash version 7.13.4 or earlier, as newer versions may encounter compatibility issues when establishing a connection with OpenSearch due to changes introduced by Elasticsearch subsequent to the fork. We strongly recommend that users test this solution with their own data to ensure effectiveness.

---

<div class="post-metadata">

**Author:** ![maxim](https://avatars.discourse-cdn.com/v4/letter/m/ba9def/32.png) [@maxim](https://forum.opensearch.org/u/maxim)\
**Post date:** [January 24, 2024, 11:32am UTC](https://forum.opensearch.org/t/nfs-repository-and-restore-elastic-snapshot/17537/4 "2024-01-24T11:32:09Z")

</div>

@pablo  
I was able to solve the problem by using `https://github.com/elasticsearch-dump/elasticsearch-dump`  
uploaded the necessary indexes into .json and then sent it as a filebit to opensearch, but first you need to use compatibility mode

```auto
PUT /_cluster/settings
{
  "persistent" : {
    "compatibility.override_main_response_version" : true
  }
}

```

thank you for your help
