Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

s3fs mount error: specified passwd_file is not readable

I am trying to port ftp server on linux ec2 instance. Password authentication file exists in /etc/passwd-s3fs with permission 600. But when I run command:

$ s3fs bucketname /home/s3/s3mnt -o passwd_file=/etc/passwd-s3fs,nonempty

It shows below error:

s3fs: specified passwd_file is not readable.

Also tried with permission 640 but same issue. Kindly help.

like image 751
Bhushan Tembhurne Avatar asked Oct 31 '25 16:10

Bhushan Tembhurne


1 Answers

After you check the permissions - make sure that the credentials file use the correct format.

If you're using ~/.aws/credentials:

[default]
aws_access_key_id=AKIAIOSFODNN7EXAMPLE
aws_secret_access_key=wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY

If you're using other credentials file (i.e. ${HOME}/.passwd-s3fs):

ACCESS_KEY_ID:SECRET_ACCESS_KEY

Additional information from the AUTHENTICATION section in here:

   The  s3fs  password  file  has  this  format  (use this format if you have only one set of
   credentials):
       accessKeyId:secretAccessKey

   If you have more than one set of credentials, this syntax is also recognized:
       bucketName:accessKeyId:secretAccessKey

   Password files can be stored in two locations:
        /etc/passwd-s3fs     [0640]
        $HOME/.passwd-s3fs   [0600]

Last check: Ensure that you're passing absolute path of the .passwd-s3fs or executing the s3fs command from the relative path.
I was stuck on that without noticing the path.

like image 152
RtmY Avatar answered Nov 02 '25 22:11

RtmY



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!