I would like to know if it's possible to give read access to a folder within another folder where the user hasn't access. For example, a user needs to access all files within /folder1/folder2/folder3/logs without having access to read files or list any files within folder1 folder2 and folder3.


1 Answer 1


You only need to grant executable bit to these directories to make the user able of reading the log file, something like:

chmod -R ugo+x /folder1

With +x they can move into these directories however without the r (read) they can't list any files and they're only able to read a specific file which they have access to.

  • But then users can access any file in /folder1 (provided they know or guess the name, which is rarely a problem). Commented Aug 2, 2017 at 21:46

You must log in to answer this question.

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