Verifying Restore Status
When restoring data from a backup snapshot, verifying the restore status is crucial to ensure the integrity and completeness of the restore operation. If you initiated a restore with the query parameter wait_for_completion=true, you can check the status of the restore using the _status endpoint.
To verify the status of a restore operation
1. Ensure your external Elasticsearch cluster is up and running.
2. Run the following command:
GET _snapshot/repo-name/backup-name/_status
In this command, replace repo-name and backup-name with your repository and backup names, respectively.
A sample command to verify the restore status is as follows:
curl -s GET http://es-host:es-port/_snapshot/myrepo/api_data_store_backup/_status
In this example:
The external Elasticsearch cluster is assumed to be running on
es-host with port
es-port.
The command queries the status of restoring a snapshot named
api_data_store_backup from a repository named
myrepo.
The JSON response from the external Elasticsearch provides detailed information about the status of the restore. The table displays the various restore status results:
Status | Description |
Success | The restore of the given backup is successfully restored with the given parameters. |
Failed | The restore process has failed. |
Started | The restore process is started and still in progress. This usually happens when the data being restore is large and you verify the status as soon as you initiate the restore process. |
Partial | The restore of the data is partially complete. |