0

Does "chmod -R 700 directory_1" update directories under softlinks? Forexample, there is a softlink under directory_1 folder: "my_softlink". And my_softlink points to a directory_2.

Will permissions of directory_2's and files under it be updated to 700 when I do "chmod -R 700 directory_1"

Best Regards

1
  • Seems like you could just try it and see...
    – martineau
    Sep 18, 2012 at 8:45

1 Answer 1

1

From the man page:

chmod never changes the permissions of symbolic links; the chmod system call cannot change their permissions. This is not a problem since the permissions of symbolic links are never used. However, for each symbolic link listed on the command line, chmod changes the permissions of the pointed-to file. In contrast, chmod ignores symbolic links encountered during recursive directory traversals.

So the answer is, no, it will not change anything for directory_2.

You must log in to answer this question.

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