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

main.ERROR Unable to access '<bucket_name>': permission denied #780

Open
NohYeongHun opened this issue Dec 27, 2023 · 3 comments
Open

main.ERROR Unable to access '<bucket_name>': permission denied #780

NohYeongHun opened this issue Dec 27, 2023 · 3 comments

Comments

@NohYeongHun
Copy link

Currently, the situation I have confirmed is as follows:

  1. Register aws credentials in the ~/.aws/credentials file
[default]
aws_access_key_id= <aws_access_key_id>
aws_secret_access_key=<aws_secret_access_key>


2. Check whether the mount folder has been properly created on the current server and s3 bucket.


nevertheless
When using goofys, an error called Permission denied occurs.
Is there anything else I need to check?

## Log
---[ REQUEST POST-SIGN ]-----------------------------
HEAD /<bucket_name>/<folder_name>/4hub3iuzc22q0x83tiskzq1g7san68fo HTTP/1.1
Host: s3.ap-northeast-2.amazonaws.com
User-Agent: aws-sdk-go/1.8.25 (go1.9.2; linux; amd64)
Authorization: AWS4-HMAC-SHA256 Credential=<Credential>
SignedHeaders=host;x-amz-content-sha256;x-amz-date, 
Signature=<Signature>
X-Amz-Content-Sha256: ...
X-Amz-Date: 20231227T082901Z


-----------------------------------------------------
2023/12/27 17:29:01.866202 s3.DEBUG DEBUG: Response s3/HeadObject Details:
---[ RESPONSE ]--------------------------------------
HTTP/1.1 403 Forbidden
Connection: close
Content-Type: application/xml
Date: Wed, 27 Dec 2023 08:29:01 GMT
Server: AmazonS3
X-Amz-Id-2: ...
X-Amz-Request-Id: ...


### error
-----------------------------------------------------
2023/12/27 17:29:01.866276 s3.DEBUG DEBUG: Validate Response s3/HeadObject failed, not retrying, error Forbidden: Forbidden
        status code: 403, request id: <request_id>, host id: <host_id>
2023/12/27 17:29:01.866309 main.ERROR Unable to access '<bucket_name>': permission denied
2023/12/27 17:29:01.866328 main.FATAL Mounting file system: Mount: initialization failed
@antoniofarina
Copy link

Same problem for me

@antoniofarina
Copy link

@NohYeongHun I have further investigated and, in my case, I discovered the ntp service crashed on my server.
Restarting the ntp solved the issue.

@lnicola
Copy link
Contributor

lnicola commented May 13, 2024

I think I've seen this happen with the S3 backend with a reverse-proxy in front of it that's configured to turn 404 errors into 403, which breaks the auto-detection in

func (s *S3Backend) Init(key string) error {
.

I didn't try to fix it by using an empty key, not sure if that could work.

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

3 participants