LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   apache forbidden root message (https://www.linuxquestions.org/questions/linux-general-1/apache-forbidden-root-message-179117/)

johann519 05-07-2004 07:11 PM

apache forbidden root message
 
I just set up a webserver on a fedora 1 machine with all the updates. When I tried to access it on my other computer to see if it worked, it gave me a forbidden message and said that I didn't have permission to acces the root. Why is apache looking in root for the site. Any help would be great. Thanks.

P.S. I looked at the root directory and it's not set to root

btmiller 05-07-2004 07:15 PM

Does apache have permission to read the webroot directory? Also you might try putting an index.html into your webroot since some configurations do not allow Apache to auto-index certain directories.

johann519 05-07-2004 07:16 PM

sorry i'm a noob, can you explain?

btmiller 05-07-2004 07:48 PM

Somewhere in your httpd.conf there will be a line that looks like:

DocumentRoot "<some directory>"

This is the root from which files are served up by the web server. Usually on default installations of RH it's /var/www/html. You need to make sure that the apache user (the user account which the server runs under) can read this directory and the files in it.

Also, there is a configuration directive (don't know the exact details) that prevents Apache from auto-indexing the conents of directories (thus providing a default index.html listing the files in the directory). To test it out, try creating an index.html in the document root and make sure Apache can read it. If you need help figuring out whether Apache can read something, look on the Web or around here for a basic guide to Unix permissions -- there are many.

johann519 05-07-2004 08:02 PM

thanks that worked


All times are GMT -5. The time now is 05:34 PM.