[GH-ISSUE #128] Getting Error "s3fs: could not determine how to establish security credentials" #81

Closed
opened 2026-03-04 01:41:50 +03:00 by kerem · 7 comments
Owner

Originally created by @qspencer on GitHub (Feb 23, 2015).
Original GitHub issue: https://github.com/s3fs-fuse/s3fs-fuse/issues/128

  1. Using an EC2 with Amazon linux
  2. A file named ".passwd-s3fs" is in $HOME
  3. The file contains one line with :
  4. Ran "chmod 600 .passwd-s3fs"
  5. libcurl version is 7.40
  6. issued command "tail -f /var/log/messages" but no s3fs messages
  7. tried "-f" option. Output was:

set_moutpoint_attribute(3482): PROC(uid=0, gid=0) - MountPoint(uid=0, gid=0, mode=40755)
s3fs: could not determine how to establish security credentials

Any solutions or suggestions of things to try would be greatly appreciated!

Originally created by @qspencer on GitHub (Feb 23, 2015). Original GitHub issue: https://github.com/s3fs-fuse/s3fs-fuse/issues/128 1. Using an EC2 with Amazon linux 2. A file named ".passwd-s3fs" is in $HOME 3. The file contains one line with <accesskeyid>:<secretaccesskey> 4. Ran "chmod 600 .passwd-s3fs" 5. libcurl version is 7.40 6. issued command "tail -f /var/log/messages" but no s3fs messages 7. tried "-f" option. Output was: set_moutpoint_attribute(3482): PROC(uid=0, gid=0) - MountPoint(uid=0, gid=0, mode=40755) s3fs: could not determine how to establish security credentials Any solutions or suggestions of things to try would be greatly appreciated!
kerem closed this issue 2026-03-04 01:41:50 +03:00
Author
Owner

@ggtakec commented on GitHub (Mar 3, 2015):

"s3fs: could not determine how to establish security credentials" message means that s3fs could not find any credential(/etc/passed-s3fs, $HOME/.passwd-s3fs etc...).
It seems that your procedure is no problem, but you got this message.
So I think that HOME environment is something wrong as possible.

If you can, you try to copy your $HOME/.passwd-s3fs to /etc/passwd-s3fs and cheek to run s3fs.

Regards,

<!-- gh-comment-id:76963402 --> @ggtakec commented on GitHub (Mar 3, 2015): "s3fs: could not determine how to establish security credentials" message means that s3fs could not find any credential(/etc/passed-s3fs, $HOME/.passwd-s3fs etc...). It seems that your procedure is no problem, but you got this message. So I think that HOME environment is something wrong as possible. If you can, you try to copy your $HOME/.passwd-s3fs to /etc/passwd-s3fs and cheek to run s3fs. Regards,
Author
Owner

@qspencer commented on GitHub (Mar 3, 2015):

thank you, I tried what you suggested and it worked!

<!-- gh-comment-id:76965434 --> @qspencer commented on GitHub (Mar 3, 2015): thank you, I tried what you suggested and it worked!
Author
Owner

@jcomeauictx commented on GitHub (Jan 29, 2017):

if you ran the s3fs command with sudo, but had the .passwd-s3fs file in your own account's $HOME, that could account for why it failed, and also why it mentioned PROC(uid=0, gid=0) in the output. it may have been looking for the file in root's home directory.

<!-- gh-comment-id:275943390 --> @jcomeauictx commented on GitHub (Jan 29, 2017): if you ran the `s3fs` command with `sudo`, but had the `.passwd-s3fs` file in your own account's `$HOME`, that could account for why it failed, and also why it mentioned `PROC(uid=0, gid=0)` in the output. it may have been looking for the file in root's home directory.
Author
Owner

@railsfans commented on GitHub (Jul 22, 2017):

把/etc/passwd-ossfs的权限改成你要启动的普通用户就行了。

<!-- gh-comment-id:317186858 --> @railsfans commented on GitHub (Jul 22, 2017): 把/etc/passwd-ossfs的权限改成你要启动的普通用户就行了。
Author
Owner

@stormm2138 commented on GitHub (Feb 22, 2018):

Note that for me using fstab didn't auto-remount on reboot, likely due to networking services not being enabled at the time of the boot mount, so I'm creating a service to boot after networking services are enabled per https://github.com/s3fs-fuse/s3fs-fuse/issues/412

<!-- gh-comment-id:367863886 --> @stormm2138 commented on GitHub (Feb 22, 2018): Note that for me using fstab **didn't auto-remount on** reboot, likely due to networking services not being enabled at the time of the boot mount, so I'm creating a service to boot **after networking services** are enabled per https://github.com/s3fs-fuse/s3fs-fuse/issues/412
Author
Owner

@blurayne commented on GitHub (Aug 31, 2018):

You could use a bash wrapper script to support a custom credential parameter using AWS CLI ENV variables - see here:
http://blog.evolution515.net/2018/08/31/autofs-indirect-user-automounter-for-aws-s3-using-either-s3fs-or-goofyfs/

<!-- gh-comment-id:417676930 --> @blurayne commented on GitHub (Aug 31, 2018): You could use a bash wrapper script to support a custom credential parameter using AWS CLI ENV variables - see here: http://blog.evolution515.net/2018/08/31/autofs-indirect-user-automounter-for-aws-s3-using-either-s3fs-or-goofyfs/
Author
Owner

@treii28 commented on GitHub (Mar 17, 2022):

my EC2 should have S3 permissions in it's default assumed role. is there any way to avoid this error when using such authentication?

<!-- gh-comment-id:1071164897 --> @treii28 commented on GitHub (Mar 17, 2022): my EC2 should have S3 permissions in it's default assumed role. is there any way to avoid this error when using such authentication?
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/s3fs-fuse#81
No description provided.