Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When accessing I'm getting this error in

[Mon Aug 20 17:07:48 2012] [error] [client X.X.X.X] (13)Permission denied: access to / denied

I have virtual host for

<VirtualHost *:80>
    DocumentRoot /home/kir/
    ServerAlias *
    ErrorLog logs/
    CustomLog logs/ common
    Options -Indexes +FollowSymLinks
    <Directory /home/kir/>
        RewriteEngine on
        Order allow,deny
        AllowOverride all
        Allow from all

DocumentRoot /home/kir/ have permissions: Permissions: drwxr-xr-x (0755); User: kir/kir

After restarting httpd I have the following in error.log:

[Mon Aug 20 17:04:39 2012] [notice] caught SIGTERM, shutting down
[Mon Aug 20 17:04:40 2012] [notice] SELinux policy enabled; httpd running as context root:system_r:httpd_t
[Mon Aug 20 17:04:40 2012] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Mon Aug 20 17:04:40 2012] [notice] Digest: generating secret for digest authentication ...
[Mon Aug 20 17:04:40 2012] [notice] Digest: done
[Mon Aug 20 17:04:40 2012] [notice] Apache/2.2.22 (Unix) DAV/2 PHP/5.3.15 configured -- resuming normal operations

As I'm using CentOs, I've tried to disabled SELinux (/etc/selinux/config.conf SELINUX=disabled ; reboot). After disabling SELinux I've tried again - the same thing, the same error (13)Permission denied...

UPD: When accessing (this file exists in DocumentRoot) the same thing (13)Permission denied.

Any ideas?

share|improve this question
Do you still get the SELinux-message in your logfile after disabling SELinux? – pkhamre Aug 20 '12 at 13:31
@pkhamre, nope, there is no SELinux message in error.log after disabling SELinux and rebooting httpd. – Kirzilla Aug 20 '12 at 13:34
What are the permissions for /home/kir ? – pkhamre Aug 20 '12 at 13:35
@pkhamre, drwx------ (0700) – Kirzilla Aug 20 '12 at 13:37
Maybe this permits Apache to access directories beyond. Can you do a test by changing mode to 0755 and see if it works? – pkhamre Aug 20 '12 at 13:41
up vote 3 down vote accepted

The parent directory of your DirectoryRoot must be accessible by Apache, so you must make sure that Apache got execute rights for /home/kir.

chmod 0755 /home/kir


chown kir:apache /home/kir
chmod 0750 /home/kir
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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