6

I'm trying to understand why I do not have access to a sub-folder in my "Downloads" folder. The folder in question has the following rights:

drw-r--r--   29 laurent  staff   986B Feb 20 14:06 Example

and whoami gives 'laurent'. So as I understand, anybody can view this folder and I am the owner.

However, when I do cd Example, I'm getting:

bash: cd: Example/: Permission denied

In fact it seems to be true of all the sub-folders in my "Downloads" folder, none of them can be accessed (without using sudo). Any idea what could be the reason?

1
  • 2
    Don't you need x permission to see inside a folder? Like drwxr-xr-x or so?
    – GEdgar
    Commented Mar 18, 2014 at 13:57

1 Answer 1

11

To be able to list or enter a directory you need execute permission

e.g

drwxr-xr-x   2 mark  staff      68 18 Mar 14:00 example

Use chmod to change the permissions, also check the setting of umask to see the default

2
  • Yes that was it, thank you. I've fixed it by running chmod -R 755 * on the folder. It seems it's actually BitTorrent which is creating all these folders with the wrong permissions. Is it possible to force a umask for a particular application?
    – laurent
    Commented Mar 18, 2014 at 14:17
  • 2
    If a program is producing different file permissions to all other programs then it is explicitly setting permissions
    – mmmmmm
    Commented Mar 18, 2014 at 14:19

You must log in to answer this question.

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