You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by andy <an...@pos.st> on 2003/04/25 15:04:09 UTC

[users@httpd] Please help me with Virtual Host Settings

Hi all, below is part of my configuration file, I have tried my best and
see what I have done wrong, but I can never get virtual host working and
it never match the <VirtualHost xx>.  How can I debug this more, so I
can see more information on the request?  Thanks.  (I have also attached
my full httpd.conf)  

Configuration
....................................................................
NameVirtualHost 202.181.239.107

#also tried replacing www.dotmatrix.com.hk in the <VirtualHost xx> tag
with the external ip, internal ip, and an A record
<VirtualHost www.dotmatrix.com.hk>  
ServerName www.dotmatrix.com.hk
DocumentRoot /vhosts/all
ErrorLog /log/www_Error_log
CustomLog /log/www_Custom_log my_log 
</VirtualHost>

<VirtualHost forum.dotmatrix.com.hk>
ServerName forum.dotmatrix.com.hk
DocumentRoot /vhosts/forum
ErrorLog /log/forum_Error_log
CustomLog /log/forum_custom_log my_log 
</VirtualHost>

Re: [users@httpd] Please help me with Virtual Host Settings

Posted by Joshua Slive <jo...@slive.ca>.
On Fri, 25 Apr 2003, andy wrote:

> Hi all, below is part of my configuration file, I have tried my best and
> see what I have done wrong, but I can never get virtual host working and
> it never match the <VirtualHost xx>.  How can I debug this more, so I
> can see more information on the request?  Thanks.  (I have also attached
> my full httpd.conf)

[Please don't attach the full httpd.conf unless it is absolutely
necessary.]

Have you tried to configure like the example give here:
http://httpd.apache.org/docs-2.0/vhosts/name-based.html
(ie, use the "*" in place of the IP address/hostname in both the
NameVirtualHost and <VirtualHost> directives.)
This configuration eliminates much confusion with internal/external IPs.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org