Change File Permissions Recursively

rajeshkumar created the topic: Change File Permissions Recursively
setting permission to 0755 recursive :
$chmod -R 0755 directory_NameHere

To find all files in /home/user/demo directory
$ find /home/user/demo -type f -print

To find all files in /home/user/demo directory with permission 777, enter:
$ find /home/user/demo -type f -perm 777 -print

Apply new permission using the -exec option as follows:
$ find /home/user/demo -type f -perm 777 -print -exec chmod 755 {} \;

To select directories and subdirectories use the following syntax:
$ find /var/www/html -type d -perm 777 -print -exec chmod 755 {} \;

More can be found in
www.cyberciti.biz/faq/howto-apply-condit…od-file-permissions/
Regards,
Rajesh Kumar
Twitt me @ twitter.com/RajeshKumarIn

Tagged :
0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x