Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recieve "BucketRegionError: incorrect region"... error when trying to backup to S3 #24

Open
maze88 opened this issue May 19, 2020 · 1 comment

Comments

@maze88
Copy link

maze88 commented May 19, 2020

Background conditions:

~$ aws configure list | grep region
region           ap-southeast-2      config-file    ~/.aws/config
~$ aws s3 mb s3://cassandra-snapshot-test
make_bucket: cassandra-snapshot-test-mz
$ aws s3api get-bucket-location --bucket cassandra-snapshot-test
{
    "LocationConstraint": "ap-southeast-2"
}
$ kubectl describe statefulsets.apps cassandra | egrep 'Namespace|Labels'
Namespace:          default
Labels:             app=cassandra
  Labels:  app=cassandra
  Labels:        <none>

In addition, I have a Keyspace on Cassandra named 'mykeyspace'.

Command and error:

$ ./cain backup -n default -l app=cassandra -k mykeyspace --dst s3://cassandra-snapshot-test
2020/05/19 12:47:24 Backup started!
2020/05/19 12:47:24 Getting clients
2020/05/19 12:47:29 BucketRegionError: incorrect region, the bucket is not in 'eu-central-1' region
    status code: 301, request id: , host id:

I don't understand where this 'eu-central-1' comes from, as I do not have anything in that region in my AWS config file or cloud.

Let me know about any additional info required...!

@maorfr
Copy link
Contributor

maorfr commented May 20, 2020

cain uses skbn to do the actual copy. Take a look at https://github.com/nuvo/skbn/blob/master/README.md#aws

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants