ES 6.5.4 and S3 repo issue

Hello,

We are trying to use the repository-s3 on our ES servers. but when we are trying to create a repository with:

PUT _snapshot/s3
{
"type": "s3",
"settings": {
"endpoint": "elasticsearch.is.working.in.the.lab.local:8082"
}
}

OR

PUT _snapshot/s3
{
"type": "s3",
"settings": {
"bucket": "elasticsearch"
}
}

We have the following error:
Method Not Allowed (Service: Amazon S3; Status Code: 405; Error Code: 405 Method Not Allowed; Request ID: 168843073; S3 Extended Request ID: null)

In elasticsearch.yml the following line is added:
s3.client.default.endpoint: "elasticsearch.is.working.in.the.lab.local:8082"

And credential has been added in the keystore via:
bin/elasticsearch-keystore add s3.client.default.access_key
bin/elasticsearch-keystore add s3.client.default.secret_key

The s3cmd is working:
New settings:
Access Key: MYACCESSKEY
Secret Key: MYSECRETKEY
Default Region: US
S3 Endpoint: elasticsearch.is.working.in.the.lab.local:8082
DNS-style bucket+hostname:port template for accessing a bucket: elasticsearch.is.working.in.the.lab.local:8082
Encryption password:
Path to GPG program: /usr/bin/gpg
Use HTTPS protocol: True
HTTP Proxy server name:
HTTP Proxy server port:

And the result of 's3cmd ls' is:
2019-01-17 13:58 s3://elasticsearch

Is there anyway to troubleshoot that? Should I open a support request?

Thanks,

L.

@phr0gz,

Please try to use the below pattern to create s3 repository:

PUT /_snapshot/s3_repository
{
  "type": "s3",
  "settings": {
    "bucket": "MYBUCKETNAME",
    "region": "xyz",
  }
}'

You also need to install repository-s3 plugin on your all elasticsearch node.

You need to store the access-key and secret-key securely using elasticsearch-keystore.

Please refer the below link for same:

https://www.elastic.co/guide/en/elasticsearch/plugins/current/repository-s3-client.html

Thanks.

Thanks, but the region setting has been removed see S3 Repository: Remove region setting by rjernst · Pull Request #22853 · elastic/elasticsearch · GitHub.
The S3 plugin is installed on all nodes.

As I said before:

@phr0gz,

Thanks for info. I was not aware about this.

I will check your error again and try to come back with solution.

Thanks.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.