How to fix Cpanel Account Permissions

Fixing file and directory permission.

find /home/*/public_html/* -type f -exec chmod 644 {} \;
find /home/*/public_html/* -type d -exec chmod 755 {} \;

we can specify user by replace * with usename

To fix the permission for all the websites.

for i in `ls /var/cpanel/users` ; do chown -R $i.$i /home/$i/public_html/* ; done

One Response to “How to fix Cpanel Account Permissions”

  1. 2tributaryon 13 Jan 2022 at 2:06 am


Trackback URI | Comments RSS

Leave a Reply

You must be logged in to post a comment.