Change Permissions Recursively
For example following command will set permissions 755 (rwxr-xr-wx) on public_html directory in home directory and all its sub directories.$ chmod -R 755 ~/public_htmlBut you don’t like to set the similar permissions on files and directories both. So what to do now, How can we set permissions different-2 on files and directories recursively.
Solution is here: Use the following commands to set all directories permission to 755 (rwxr-xr-wx) and all files permissions to 644 (rw-r–r–)
Set Permissions on Directories:
$ find ~/public_html -type d -exec chmod 755 {} ;
Set Permissions on Files:
$ find ~/public_html -type f -exec chmod 644 {} ;
Comments
Post a Comment