Tuesday, November 1, 2011

How to change permission in Linux

If you want to change the permission for some files or directories in Linux do this:


sudo -s
cd /dir1
find dir1/ -type f -perm 555 (if you just want to see that files)

find dir1/ -type f -perm 555 -exec chmod 644 {} \;
find dir1/ -type d -perm 555 -exec chmod 755 {} \;
ls -l

No comments: