Skip to content

Commit

Permalink
docs: update opensearch dashboards index name in dr docs
Browse files Browse the repository at this point in the history
  • Loading branch information
lunkan93 committed Dec 12, 2024
1 parent c86d6e9 commit 9bb050b
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions docs/operator-manual/disaster-recovery.md
Original file line number Diff line number Diff line change
Expand Up @@ -239,35 +239,35 @@ Read the [documentation](https://opensearch.org/docs/latest/opensearch/snapshot-

#### Restoring OpenSearch Dashboards data

Data in OpenSearch Dashboards (saved searches, visualizations, dashboards, etc) is stored in the index `.opensearch_dashboards_x`. To restore that data you first need to delete the index and then do a restore.
Data in OpenSearch Dashboards (saved searches, visualizations, dashboards, etc) is stored in the indices pointed to by the alias `.kibana`. To restore that data you first need to delete the index and then do a restore.

This will overwrite anything in the current `.opensearch_dashboards_x` index. If there is something new that should be saved, then [export](https://www.elastic.co/guide/en/kibana/7.10/managing-saved-objects.html#_export) the saved objects and [import](https://www.elastic.co/guide/en/kibana/7.10/managing-saved-objects.html#_import) them after the restore.
This will overwrite anything in the current `.kibana_x` index. If there is something new that should be saved, then [export](https://www.elastic.co/guide/en/kibana/7.10/managing-saved-objects.html#_export) the saved objects and [import](https://www.elastic.co/guide/en/kibana/7.10/managing-saved-objects.html#_import) them after the restore.

There can be multiple `.opensearch_dashboards` indices in OpenSearch, the current index should be the one you want to restore. To view your dashboard indices, follow these steps.
There can be multiple `.kibana` indices in OpenSearch, the current index should be the one you want to restore. To view your dashboard indices, follow these steps.

```bash
snapshot_name=<Snapshot name from previous step>

curl -kL -u "${user}:${password}" -X GET ${os_url}'/.opensearch_dashboard*?pretty' | jq 'keys'
curl -kL -u "${user}:${password}" -X GET ${os_url}'/.kibana*?pretty' | jq 'keys'
```

If multiple `.opensearch_dashboards_x` indices show up, run this to see the index that the alias is currently looking at.
If multiple `.kibana_x` indices show up, run this to see the index that the alias is currently looking at.

```bash
curl -kL -u "${user}:${password}" -X GET ${os_url}'/_alias/.opensearch_dashboard*?pretty' | jq 'keys'
curl -kL -u "${user}:${password}" -X GET ${os_url}'/_alias/.kibana*?pretty' | jq 'keys'
```

Make sure that the index you want to restore also exists on the snapshot. (May be an issue if you are using an old snapshot)

```bash
curl -kL -u "${user}:${password}" -X GET "${os_url}/_snapshot/${snapshot_repo}/${snapshot_name}?pretty" | jq '.snapshots[].indices' | grep .opensearch_dashboards
curl -kL -u "${user}:${password}" -X GET "${os_url}/_snapshot/${snapshot_repo}/${snapshot_name}?pretty" | jq '.snapshots[].indices' | grep .kibana
```

> [!NOTE]
> If you visit the `"<os_url>/app/dashboards"` page in the OpenSearch GUI after deleting the index and before restoring the index, another empty index `.opensearch_dashboards` will be created. You need to delete this manually, which can be done with:
> If you visit the `"<os_url>/app/dashboards"` page in the OpenSearch GUI after deleting the index and before restoring the index, another empty index `.kibana` will be created. You need to delete this manually, which can be done with:
>
> ```bash
> curl -kL -u "${user}:${password}" -X DELETE "${os_url}/.opensearch_dashboards?pretty"
> curl -kL -u "${user}:${password}" -X DELETE "${os_url}/.kibana?pretty"
> ```
```bash
Expand Down

0 comments on commit 9bb050b

Please sign in to comment.