How to mass change Files and Folders permission on a Linux server

In this tutorial I will explain how to mass change permission of all files and folders/directory on a Linux server.
Login to server via SSH as root and execute following commands.

To change permission of all files and folders to 644 in /home/username/pulic_html

chmod 644 /home/username/public_html -R

To change permission of all files to 644 in /home/username/pulic_html

cd /home/username/pulic_html
find . -type f -exec chmod 644 {} \;

To change permission of all folder to 755 in /home/username/pulic_html

cd /home/username/pulic_html
find . -type d -exec chmod 755 {} \;

[dedicated_hosting]

Our Top Rated Host

Related Posts