guyson / s3fs

Automatically exported from code.google.com/p/s3fs
GNU General Public License v2.0
0 stars 0 forks source link

Apache (13)Permission denied issue - 403 #446

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi Guys,
I'm aware that it's a known issue and I've read about 10 issues and still not 
able to fix this after 2 days of working on it.

0. configurations:
{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": "s3:*",
      "Resource": "*"
    }
  ]
}

chmod 600 ~/.passwd-s3fs
/etc/fstab:

s3fs#xxxx /s3 fuse netdev,default_acl=public 
read,use_cache=/tmp/cache,use_rrs=1,allow_other 0 0

1.Mount works OK:
s3fs -o use_cache=/tmp/cache -o allow_other,uid=33,gid=33 -o 
default_acl="public-read" setsdrive /s3
fuse: warning: library too old, some operations may not not work

note- tried others way to mount also (command is mention later)

2. r/w files works fine
mkdir /s3/test
 ll
total 0
drwxrwxrwx. 1 33 tape 0 Dec  8 14:58 server
drwxrwxr-x. 1 33 tape 0 Dec 10 18:50 test

3. apache configurations:
#mySer server alias
Alias /pic/ "/s3/server/pics/"
#Alias /pic/ "/tmp/cache/xxx/server/pics/"
<Directory "/usr/server/pics">
       Options FollowSymLinks
       AllowOverride None
</Directory>

4. The Issue:
when trying to get any file from that folder "pics", I get 403
(13)Permission denied: access to /pic/pic256.jpg denied

all files has 777/755 permissions  but I still get http 403 over "/s3"
tried working with the cache folder and got the same results
tried changing the root folders permissions to 777

Version of s3fs being used (s3fs 1.74):

Version of fuse being used (2.8.3):

System information (Linux xxxx.eu-west-1.compute.internal 
2.6.32-358.14.1.el6.x86_64 #1 SMP Mon Jun 17 15:54:20 EDT 2013 x86_64 x86_64 
x86_64 GNU/Linux):

Distro (cat /etc/issue):
Red Hat Enterprise Linux Server release 6.4 (Santiago)
Kernel \r on an \m

s3fs command line used (if applicable):
tried all 3:
1. s3fs -o use_cache=/tmp/cache -o allow_other -o default_acl="public-read" xxx 
/s3
2. s3fs -o use_cache=/tmp/cache -o allow_other,uid=33,gid=33 -o 
default_acl="public-read" xxx /s3
3. s3fs -o default_acl=public-read,use_cache=/tmp/cache,use_rrs=1,allow_other 
xxx /s3
/etc/fstab entry (if applicable):

s3fs syslog messages (grep s3fs /var/log/syslog):
not exist

Original issue reported on code.google.com by amitbis...@gmail.com on 11 Dec 2014 at 12:06

GoogleCodeExporter commented 9 years ago
after 3 days i've found the solution:

Alias /pic/ "/s3/server/pics/"
<Directory "/s3/">
    Options Indexes FollowSymLinks Includes ExecCGI
    AllowOverride All
    Allow from all
</Directory>

only now it's working

Original comment by amitbis...@gmail.com on 11 Dec 2014 at 6:24

GoogleCodeExporter commented 9 years ago
Plus selinux must be disabled

Original comment by amitbis...@gmail.com on 15 Dec 2014 at 12:06

GoogleCodeExporter commented 9 years ago
Hi,

I'm sorry for replying late.
Do you have been had any problem yet?
(It seems that you can solve this problem.)

If you do not solve, you can see s3fs's log by "-f" or "-d" option with 
manually running.

I'm going to close this issue.
So s3fs project have been moved to 
Github(https://github.com/s3fs-fuse/s3fs-fuse).
If you have any problem about s3fs, please post new issue on Github.

Thanks in advance for your help.

Original comment by ggta...@gmail.com on 7 Feb 2015 at 5:37