ES is capable of automatic backup, which involves automatically creating a snapshot of the primary index shards in a cluster and backing it up to COS. The snapshot can be restored to the cluster as needed.
Note:
This feature is currently free of charge.
Click Kibana on the cluster details page to enter the Kibana console where you can view the repository of all cluster snapshots using ES API on the "Dev Tools" page.
GET _snapshot?pretty
If only automatic snapshot is performed, the following message will be returned:{
"ES_AUTO_BACKUP": {
"type": "cos",
"settings": {
"bucket": "es-ap-guangzhou",
"base_path": "/es_backup/es-2s8x1b9u",
"chunk_size": "500mb",
"region": "ap-guangzhou",
"compress": "true"
}
}
}
GET _snapshot/ES_AUTO_BACKUP/_all?pretty
The returned result is as follows:If there are no snapshots, the list will be empty.
{
"snapshots": []
}
{
"snapshots": [
{
"snapshot": "es-2s8x1b9u_20181220",
"uuid": "gsXPyWb1SNOlTuj3eNs2gA",
"version_id": 5060499,
"version": "5.6.4",
"indices": [
".kibana"
],
"state": "SUCCESS",
"start_time": "2018-12-20T08:00:12.336Z",
"start_time_in_millis": 1545292812336,
"end_time": "2018-12-20T08:00:12.945Z",
"end_time_in_millis": 1545292812945,
"duration_in_millis": 609,
"failures": [],
"shards": {
"total": 1,
"failed": 0,
"successful": 1
}
}
]
}
POST _snapshot/ES_AUTO_BACKUP/es-2s8x1b9u_20181220/_restore
Was this page helpful?