Hello All,
I am trying to learn elasticsearch by building an app. I wanted to see what snapshots looks like and finally have it in aws elasticsearch with some API gateway on top of it.
It doesn't seem to go as planned. I have the following these versions:
Version: 5.5.1, Build: 19c13d0/2017-07-18T20:44:24.823Z, JVM: 1.8.0_131
ubuntu 16.04.2
File System snapshot
##/etc/elasticsearch/elasticsearch.yml
path.repo: /opt/elasticsearch/backup
My request is:
curl -XPUT 'http://localhost:9200/_snapshot/gontbackup' -H 'Content-Type: application/json' -d '{
"type": "fs",
"settings": {
"compress": true,
"location": "gontbackup"
}
}'
The response is shown below but I could not see anything in the folder so I am not sure if it's just taking time(which should not since my data is very small)
{"acknowledged":true}
S3 Snapshot
I installed the s3 repository elasticserach plugin and created an Admin Access IAM to start with in order to avoid permission issues.
my request is
curl -XPUT 'http://localhost:9200/_snapshot/gont2106' -H 'Content-Type: application/json' -d '{
"type": "s3",
"settings": {
"bucket": "thebudcke",
"base_path": "snapshot2016",
"region": "us-east-1",
"access_key":"xxx",
"secret_key": "xxx"
}
}'
{"error":{"root_cause":[{"type":"repository_exception","reason":"[gont2106] failed to create repository"}],"type":"repository_exception","reason":"[gont2106] failed to create repository","caused_by":{"type":"amazon_s3_exception","reason":"Bad Request (Service: Amazon S3; Status Code: 400; Error Code: 400 Bad Request; Request ID: 176FD5687AA9A2AD)"}},"status":500}
Can anyone help? What does acknowledged do and how to check and what can be wrong with the s3 repository
Thanks