Unable to access S3 repos after 0.9.5 upgrade

Just upgraded from 0.9.4 to 0.9.5 on 2 boxes. Both environments have been setup to backup to a AWS S3 based repository.

However when using 0.9.5 I get the following error

Fatal: unable to open config file: Stat: Head https://xxx.s3.dualstack.us-east-1.amazonaws.com/gitlab/config: 301 response missing Location header
Is there a repository at the following location?

If I use 0.9.4 everything is fine. Version is AMD64 (running on Ubuntu 16.04 and AWS Linux).

Is it just me or anyone else seeing this as well?

Hey, welcome to the forum! We’ve seen this error during testing, the credentials used for accessing S3 need the GetBucketLocation privilege. Can you check if the account misses this privilege and report back? Thanks!

Here’s a bit of background:

1 Like

Thanks for the quick reply (also on Twitter).

Checked the permissions for this access key and here they are:

    "Sid": "Stmt1510567777000",
    "Effect": "Allow",
    "Action": [

Seems to be missing GetBucketLocation. Will ask my fellow AWS guru nicely to update this and let you know if this fixes my issue.

1 Like

OK, can confirm that our AWS policy for this bucket was missing the GetBucketLocation.

Added that in and now 0.9.5 works like a charm. It is in the docs but our policy was setup before https://github.com/restic/restic/issues/1593 was reported and fixed. And up until 0.9.4 this has worked fine so that was surprising when 0.9.5 suddenly failed.

Thanks for your help @fd0 !


Awesome, thanks for the feedback! Now people will hopefully search the forum for the error message (and it’ll probably turn up in Google search results too) :slight_smile:

1 Like

It has also come up in an issue here: