2

It seems that I can't access a folder on which I put 777 group permissions, even though I am a member of the folder's group.

Error detail :

10:57 ~ $ ls -l
d---rwx---  2 laurent www-data  4096 août  30 10:28 test
10:57 ~ $ cd test
bash: cd: test: Permission denied

I am a member of the group www-data, and this group has read, write and execute access to the folder, shouldn't I be able to access it?

Other informations :

10:57 ~ $ whoami
laurent
10:58 ~ $ id
uid=1000(laurent) gid=1000(laurent) groups=1000(laurent),4(adm),24(cdrom),27(sudo),30(dip),33(www-data),46(plugdev),107(kvm),115(lpadmin),131(sambashare)

Everyone has rights to this folder (my home directory) :

11:00 ~ $ pwd
/home/laurent
11:00 ~ $ ls -l /
drwxr-xr-x   3 root root  4096 oct.  20  2017 home
11:00 ~ $ ls -l /home/
drwxr-xr-x 69 laurent laurent 4096 août  30 10:48 laurent
3

If the user matches the owner of the object, then the permissions for the user are used, ignoring the group and others permissions.

As the user "laurent" has absolutely no permissions on the directory, access is denied -- even though "laurent" is also in a group the does have permissions.

  • It seems to be the right answer. If I set an other user as the folder owner, I can access it. Thanks ! – Laurent POSTIC Aug 30 '18 at 9:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.