Apache "No Permission" - 403 forbidden

Solution 1:

A number of things could be going wrong.

First thing is to look in your error log (maybe in /var/log/apache2/error_log) and look for the Apache reason for failing to serve this location.

Next is to check your directory permissions up to your document root. E.g. if your document root is in /var/www/htdocs then you need to ensure the Apache user has +x permissions on the directories /, /var, /var/www, and /var/www/htdocs.

Test whether you can access these directories yourself:


su www-data
ls /
ls /var
ls /var/www
ls /var/www/htdocs
exit

Are you sure www-data is the right user? Try typing ps uax and look for the user the Apache process is running as.

Otherwise it could be Apache deciding not to serve the files for some other reason.

Solution 2:

This is likely a result of not having an index.html file in that directory and your Apache directives not allowing you to view directory listings. Try putting some text in an index.html file in your document root.