Here's an excerpt from my httpd.conf file:
#
# Use name-based virtual hosting.
#
NameVirtualHost 63.163.109.231:80
#
# Virtual hosts
#
# Virtual host www.befumo.com
<VirtualHost 63.163.109.231:80>
DocumentRoot /var/www/html/befumo/
ServerAdmin webm...@befumo.com
ServerName www.befumo.com
ServerAlias befumo.com www.befumo.com
DirectoryIndex index.htm
</VirtualHost>
...
I Ran
chcon -R -h -t httpd_sys_content_t /var/www/html/
When I do an ls -aZ /var/www/html/befumo/
I get the following:
-rw-r--r-- root root root:object_r:httpd_sys_content_t hello.html
-rw-r--r-- root root root:object_r:httpd_sys_content_t index.htm
...
Which I assume is what it's supposed to be.
ls -Z in /var/www/html shows the following:
drwxr-xr-x apache apache root:object_r:httpd_sys_content_t befumo
-rw-r--r-- root root root:object_r:httpd_sys_content_t hello.html
drwxr-xr-x apache apache root:object_r:httpd_sys_content_t
pleasantmountpress
drwxrwxrwt apache apache root:object_r:httpd_sys_content_t rbefumo
drwxr-xr-x apache apache root:object_r:httpd_sys_content_t rootwerx
I created a simple test page (hello.html) in my /var/www/html/befumo/
directory
If I go to the browser and enter:
http://localhost/befumo/index.htm
I see the correct page.
If I go to http://www.befumo.com/hello.html (the test page I created)
I see the right page,
However,
if I go to http://www.befumo.com/index.htm
I get a 404 Page not found error.
If I go to http://www.befumo.com
I see the default Apache test page.
If I change my virtual host as follows:
DirectoryIndex hello.html
No change, which has me really perplexed.
Any suggestions would be greatly appreciated.
Thanks.
Joe
The hello.html page I'm seeing is in the /var/www/html/ directory, not the
/var/www/html/befumo/ directory, where I thought it should be looking. So it
seems as if Apache is not looking into any of my virtual server directories,
if that makes any kind of sense.
/var/www/html/ directory, and now that shows up as default for every one of
my websites. For some reason they're not looking in the individual
subdirectories identified in the virtual hosts sections.