0

I have one domain hosted on server domain.com, there are about 20 subdomains as addon domains there. For no good reason someone has changed (chgrp) on all files in domain.com directory to domain.com user now all websites are showing 403 forbidden access error. What should i do now to resume websites. I have tried changing php handler but no luck yet :/ php5 handler is suphp and Apache suEXEC is on....

0

That looks your file permission or ownership has problems.

try to have the following permissions.

Directories: 755

To change all direcotry permissions to 755 under linux use the following command.

find . -type d -print0 | xargs -I {} -0 chmod 0755 {}

File: 644

To change all file permissions to 644 under linux use the following command.

find . -type f -print0 | xargs -I {} -0 chmod 0644 {}

The file owner should be the user who is running web server, in standard centos server it is apache, on ubuntu its www-data or nobody.

To change the group ownner and group use the following command. cd into the web root directory first.

chown apache:apache . -R

if you dont have access to ssh try do that on ftp client.

1
  • what should be php handler if i want to chown apache:apache . -R ? – ehmad11 Sep 23 '12 at 8:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.