httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier>
Subject Re: [users@httpd]
Date Thu, 30 Apr 2009 13:44:14 GMT
Rocco Scappatura wrote:
> Thanks Karel for your answer.
> On Mer, 29 Aprile 2009 19:34, Karel Kubat wrote:
>>> <VirtualHost *:80>
>>>    ServerAdmin
>>>    DocumentRoot "C:/Apache2.2/htdocs/virtualhost2"
>>>    ServerName
>>>    ErrorLog "logs/"
>>>    CustomLog "logs/" common
>>> </VirtualHost>
> I forgot to mention the default virtual host just before the one above
> that is sit in my virtual host conf file:
> <VirtualHost *:80>
> 	ServerName
> 	DocumentRoot "C:/Apache2.2/htdocs"
> </VirtualHost>
>> Please read
>> Basically you will need two virtual hosts listening to *:80. The first
>> one must have a ServerAlias and the second one
>> That should do the trick.
> Anyway I added the ServerAlias directive as well but nothing of good has
> happened.. :-(
> Please read what I report below again (I think that this is the key of the
> mistake):
>>> Basically it happens that the request for is
>>> seen by
>>> Apache as a request for / (no matter what is the virtual host) and so
> proxied to Tomcat.
> So I think that the header Host: is considered after mod_proxy and so the
> request is forwarded to Tomcat.
With respect, I think that this does not make sense.
Apache has to first parse the Host: header, before it even knows which 
<VirtualHost> should handle the request.  So it can certainly not apply 
any specific VirtualHost section directive before it has read and 
understood this header.

Think of another scenario to confirm/deny.

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message