[SATLUG] Apache <VirtualHost> issue

Matt Valdes mattvaldes at satx.rr.com
Wed Nov 10 21:09:19 CST 2004


As may have been explained in a previous post, you need a <Virtual Host>
block for the original address, as well as the new address (which you
already entered). The www.anotherwebaddress.com block should be listed
second.

This documentation is extremely helpful. It may fill in some blanks.
http://httpd.apache.org/docs-2.0/vhosts/name-based.html

-Matt

-----Original Message-----
From: satlug-bounces at satlug.org [mailto:satlug-bounces at satlug.org] On
Behalf Of David Salisbury
Sent: Wednesday, November 10, 2004 6:10 PM
To: The San Antonio Linux User's GroupMailing List
Subject: [SATLUG] Apache <VirtualHost> issue

I've got a virtual hosting question on Apache if anyone's had any
experience 
with such a topic.

Here's what's happening, which is not quite what I want:

I've got a web server running just like it should, working fine.  If you
go 
to it by its name or by IP address, everything is working fine.  I've
now, 
where our DNS is housed, set up another web address (say, 
www.anotherwebaddress.com, just an example, have no clue if that's a
real 
site) to point to this same IP address.  I've added a <VirtualHost>
block to 
my httpd.conf, restarted apache, and wah-lah, www.anotherwebaddress.com 
pulls up like I imagined.  Problem is, now, if I reference the site by
IP 
address, it ALSO pulls up whatever www.anotherwebaddress.com pulls up!
I 
don't want it to do that, I want it to continue pulling up the original 
DocumentRoot like it was before I added the <VirtualHost> block.

So it seems that adding that <VirtualHost> block is, in effect, changing
the 
DocumentRoot for the whole server.  Anybody know a directive I can put
in 
that will short circuit that from happening, or at least know why it may
be 
happening?

Thanks,
David

_______________________________________________
Satlug mailing list
Satlug at satlug.org
http://alamo.satlug.org/mailman/listinfo/satlug



More information about the Satlug mailing list