Apache Vhost content crossover issue

I have an Apache server that has multiple Virtual Hosts configured as Virtual Named Hosts (they are all looking at the same IP address). I have a primary web directory (/web), of which some subdirectories have been made into Vhosts. My Virtual Host setup is working, but I have an issue:

Example:
I have a Virtual Host www.mysite.com, which is mapped to /web/mysite. The user can access the site with no problems. The following directories exist: /web/mysite/doc, and /web/doc. If the user tries to go to: www.mysite.com/doc, they are instead directed to /web/doc on the server.

My Vhost entries all have the following format:
<VirtualHost *:80>
DocumentRoot /web/mysite
ServerName mysite.web.com

I’ve tried tweaking the config files in various ways, but I haven’t had any success so far. Has anyone ever run into this?

Hi,

That sounds odd. Could you post your virtualhost config?

Thanks,

Martin.

Agreed! The problem description appears to point to a “catch all” in the httpd-vhosts.conf which is automatically creating new virtual domains for EVERY subdirectory. THAT is why we need to look at your configuration file.

Regards,

DK

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.