I just installed Fedora Core 3 on my server (a reformat from RedHat9) and I'm having problems with my webserver.
Short and sweet:
I have a partition mounted to /web and thats the directory I'm using to serve files. I have DocumentRoot "/web/html" and [Directory "/web/html"] correctly stated in the conf file, but when I try to start apache, it tells me "DocumentRoot must be a directory"
II just doesnt seem to like serving files from any mounted drive unless its part of / I've tried mounting it to other places, but that doesnt help either.
The only way httpd will load correctly is if the directory is on hda2 (/).
Lines 265-291 from /etc/httpd/conf/httpd.conf
DocumentRoot "/web/html"
#
# Each directory to which Apache has access can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories).
#
# First, we configure the "default" to be a very restrictive set of
# features.
#
Options FollowSymLinks
AllowOverride None
#
# Note that from this point forward you must specifically allow
# particular features to be enabled - so if something's not working as
# you might expect, make sure that you have specifically enabled it
# below.
#
#
# This should be changed to whatever you set DocumentRoot to.
#
[Directory "/web/html"]
Then when I try to start httpd:
[root@tuxserver conf]# service httpd start
Starting httpd: Syntax error on line 265 of /etc/httpd/conf/httpd.conf:
DocumentRoot must be a directory [FAILED]
And yes, /web/html is a directory:
[root@tuxserver conf]# ls -l /web
total 16
drwxr-xr-x 14 webaccess webaccess 4096 Feb 20 21:48 html
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 lost+found
[root@tuxserver conf]# ls -l /web/html
total 844
-rw-r--r-- 1 webaccess webaccess 0 Feb 20 21:48 default.ida
-rw-r--r-- 1 webaccess webaccess 415455 Feb 20 21:48 difference.jpg
-rw-r--r-- 1 webaccess webaccess 7346 Feb 20 21:48 eqoa.html
-rw-r--r-- 1 webaccess webaccess 13155 Feb 20 21:48 ff1.mid
drwxr-xr-x 8 webaccess webaccess 4096 Feb 20 21:48 images
-rw-r--r-- 1 webaccess webaccess 579 Feb 20 21:48 index.htm
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 kelli
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 legends
-rw-r--r-- 1 webaccess webaccess 283427 Feb 20 21:48 Longhorn Spheres.jpg
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 mikee
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 nescase
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 pg
drwxr-xr-x 6 webaccess webaccess 4096 Feb 20 21:48 sbd
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 sig
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 temp
-rw-r--r-- 1 webaccess webaccess 123 Feb 20 21:48 temp.html
drwxr-xr-x 4 webaccess webaccess 4096 Feb 20 21:48 tf
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 usage
Any help would be greatly appreciated. Thanks, all.
[Edit] I found out today that there are problems with Apache and SELinux. Heh, who knew, lol.
Short and sweet:
I have a partition mounted to /web and thats the directory I'm using to serve files. I have DocumentRoot "/web/html" and [Directory "/web/html"] correctly stated in the conf file, but when I try to start apache, it tells me "DocumentRoot must be a directory"
II just doesnt seem to like serving files from any mounted drive unless its part of / I've tried mounting it to other places, but that doesnt help either.
The only way httpd will load correctly is if the directory is on hda2 (/).
Lines 265-291 from /etc/httpd/conf/httpd.conf
DocumentRoot "/web/html"
#
# Each directory to which Apache has access can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories).
#
# First, we configure the "default" to be a very restrictive set of
# features.
#
Options FollowSymLinks
AllowOverride None
#
# Note that from this point forward you must specifically allow
# particular features to be enabled - so if something's not working as
# you might expect, make sure that you have specifically enabled it
# below.
#
#
# This should be changed to whatever you set DocumentRoot to.
#
[Directory "/web/html"]
Then when I try to start httpd:
[root@tuxserver conf]# service httpd start
Starting httpd: Syntax error on line 265 of /etc/httpd/conf/httpd.conf:
DocumentRoot must be a directory [FAILED]
And yes, /web/html is a directory:
[root@tuxserver conf]# ls -l /web
total 16
drwxr-xr-x 14 webaccess webaccess 4096 Feb 20 21:48 html
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 lost+found
[root@tuxserver conf]# ls -l /web/html
total 844
-rw-r--r-- 1 webaccess webaccess 0 Feb 20 21:48 default.ida
-rw-r--r-- 1 webaccess webaccess 415455 Feb 20 21:48 difference.jpg
-rw-r--r-- 1 webaccess webaccess 7346 Feb 20 21:48 eqoa.html
-rw-r--r-- 1 webaccess webaccess 13155 Feb 20 21:48 ff1.mid
drwxr-xr-x 8 webaccess webaccess 4096 Feb 20 21:48 images
-rw-r--r-- 1 webaccess webaccess 579 Feb 20 21:48 index.htm
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 kelli
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 legends
-rw-r--r-- 1 webaccess webaccess 283427 Feb 20 21:48 Longhorn Spheres.jpg
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 mikee
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 nescase
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 pg
drwxr-xr-x 6 webaccess webaccess 4096 Feb 20 21:48 sbd
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 sig
drwxr-xr-x 3 webaccess webaccess 4096 Feb 20 21:48 temp
-rw-r--r-- 1 webaccess webaccess 123 Feb 20 21:48 temp.html
drwxr-xr-x 4 webaccess webaccess 4096 Feb 20 21:48 tf
drwxr-xr-x 2 webaccess webaccess 4096 Feb 20 21:48 usage
Any help would be greatly appreciated. Thanks, all.
[Edit] I found out today that there are problems with Apache and SELinux. Heh, who knew, lol.
