running 2 site on one apache - need help

Ed Hill ed at eh3.com
Thu Dec 4 22:24:53 EST 2003


On Thu, 2003-12-04 at 21:36, Dave Peters wrote:
> Hi all,
> 
> I have redhat 9.0 linux setup with apache web server.
> I run single web site, the server runs perfect without
> any error. I try to run 2 web site on one apache and
> cause big problem: i.e. nothing coming. Any help are
> very appreciated.
> 
> What I did for setup 2 web site:
> 1) the site location: /var/www/www.site1.com &
> /var/www/www.site2.com
> 2) I edit httpd.conf add the virtalhost:
> *************************
> Listen 80
> 
> NameVirtualHost *:80
> <VirtualHost 192.168.1.110>
> ServerName www.site1.com
> DocumentRoot /var/www/www.site1.com
> 
> </VirtualHost>
> 
> <VirtualHost 192.168.1.110>
> ServerName www.site2.com
> DocumentRoot /var/www/www.site2.com
> 
> </VirtualHost>
> **************************
> 3. I can start httpd without error.
> 4. I could not open both site when I browse it
> 
> What did I miss? Any httpd.conf need to add? Any help
> are very appreciated.


Hi Dave,

I'm currently running a few name-based VHosts on two RH 9 systems and
they work well.  I think your config file is close but have you tried
something more like:

===

NameVirtualHost *

<VirtualHost *>
   ServerName name0.org
   ServerAlias other.name0.org
   DocumentRoot /some/place0
</VirtualHost>

<VirtualHost *>
   ServerName name1.org
   ServerAlias www.name1.org
   DocumentRoot /some/place1
</VirtualHost>

===

If you want more specifics, you may email me off-list and I'll try to
help.

Ed

-- 
Edward H. Hill III, PhD
office:  MIT Dept. of EAPS;  Room 54-1424;  77 Massachusetts Ave.
            Cambridge, MA 02139-4307
email:   eh3 at mit.edu,  ed at eh3.com
URL:     http://web.mit.edu/eh3/
phone:   617-253-0098
fax:     617-253-4464
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.blu.org/pipermail/discuss/attachments/20031204/878af3cc/attachment.sig>


More information about the Discuss mailing list