httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jessica Rasku <>
Subject Re: [users@httpd] No Luck wuth VirtualHosts
Date Thu, 06 Oct 2005 22:33:35 GMT
kloomis wrote:
> Hello:
> I'm having no luck with virtual hosts.
> I have a domain name: and a sub-domain name:
> I would like to go to /var/www/sites/prod and 
> to go to /var/www/sites/dev
> My hosts file reads: localhost.localdomain 
> localhost asus
> (do I need a in here?)

Yes I believe you do.  Though it maybe should go through a DNS server, 
but this isn't a live domain.  So that will work.

> My httpd.conf has this:
> listen 80
> ServerName
> NameVirtualHost *:80
> <VirtualHost *:80>
>     DocumentRoot /var/www/sites/prod
>     ServerName
> </VirtualHost>
> <VirtualHost *:80>
>     DocumentRoot /var/www/sites/dev
>     ServerName
> </VirtualHost>
> What happens is that either or go to the 
> first VirtualHost whichever one I put first.
> What am I missing?

I'm not totally with it, though it should work from what I'm seeing 
there.  Are you restarting the server after every change?  Apache only 
reads the config file when it starts up, or when it recieves a SIGHUP (I 
think that's right).  So you need to be sure you're doing that.


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