Archive

Posts Tagged ‘apache’

“Forbidden you do not have permission to view / on this server”

February 5th, 2009

You might get this error on a fresh install of Apache (or WAMP). The solution to this problem involves editing your httpd.conf file. On Red Hat machines, this file is located in the /etc/httpd/conf/ directory. You will need to be root in order to edit this file. I highly suggest making a backup copy of httpd.conf before making any edits.

Anyway, look for something like this:

<Directory />
Options FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
</Directory>

Pay particular attention to the “Order” and “Deny” lines. By default Apache is “denying” all. To allow users to view the site, just comment out those two lines so that your directive looks like this:

<Directory />
Options FollowSymLinks
AllowOverride None
#Order deny,allow
#Deny from all
</Directory>

Now restart Apache from the command line:

[server_name]# apachectl restart

Side note: if you want to check the httpd.conf syntax before restarting apache, just type “apachectl configtest” at the command line.

apache