4

I'm trying to set up a backup system with s3fs and the Amazon S3 service. I followed this this guide and this guide.

Tailing /var/log/messages I get:

Aug 28 13:37:46 server s3fs:###response=403

I already tried creating the authentication file /etc/passwd-s3fs and setting the access and private key, passing it through the command line. I checked several times the credentials and I used it with s3fox, and it is working.

I also have set the time of the machine (with the date command) to be the same as the Amazon S3 servers (I got the time of the S3 server uploading a file with the file manager).

Not only does rsync not work, commands like ls or cp in /mnt/s3 didn't work also.

4 Answers 4

1

You can actually store the credentials in two places. System level or user level. Not clear from your question where you have things set. Each requires different permission settings.

For system level placement in /etc/passwd-s3fs the permissions should be 640. So adjust with chmod like so if that is not the case:

sudo chmod 640 /etc/passwd-s3fs

For user level placement in ~/.passwd-s3fs the permissions should be 600. So adjust with chmod like so if that is not the case:

chmod 600 ~/.passwd-s3fs

Also, the contents of each of those files should follow the fairly simple format of AccessKey:SuperSecretKey with nothing else needed. AccessKey on one side of the colon (:) ad the SuperSecretKey on the other side.

1

Hi some few times I also mount s3 bucket on linux. I noted the below link for this. Normal documentation miss an important note about permissions. So first you need to unmout the location then change permissions of both key and directory then mount again.

Your mount directory permission must be 777 and key file permission must be 600. Please check below documentation.

chmod 777 /mnt/dir/
chmod 600 ~/.passwd-s3fs

Mount AWS S3 bucket to Ubuntu file system

Hope this will help because I use that documentation many times on cloud.

0

triple check the credentials in /etc/passwd-s3fs

also, be sure the bucket name you're using is your bucket name (i.e., it is unique to you) (i.e., don't use a bucket name "test" or something like that because it is unlikely that you own/claimed the bucket name; bucket names are in a global namespace with everyone else's bucket names)

also, s3fs does not create buckets; you would need to use another s3 tool to create the bucket first, and then mount it with s3fs

1
  • all of that has been checked, and it still didn't worked Aug 31, 2010 at 2:32
0

Check if s3fs mount is using correct port, you have to use the port 9000 or the NodePort corresponding to 9000 in case of k8s svc

minio-service NodePort 172.19.32.41 9090:30302/TCP,9000:31557/TCP 34m

(app-root) bash-4.2# s3fs test /share1 -o passwd_file=~/minio.creds -o url=http://10.9.0.12:31557 -o use_path_request_style

(app-root) bash-4.2# cp anaconda-post.log /share1

(app-root) bash-4.2# ls /share1 anaconda-post.log

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .