Hi again all,

i think i found one solution for my own problem.  I commented out all the virtual 
hosting stuff from the apache httpd.conf file, and instead configured virtual hosting 
in tomcat server.xml file, adding a default host to the Engine element, and then 
defining a second Host element for the second URL.  And it worked!  But if anyone has 
any alternative approaches, or suggestions, i would certainly be interested.

thanks,
paul lomack

----- Original Message ----- 
From: Paul 
To: Tomcat Users List 
Sent: Thursday, November 13, 2003 6:44 PM
Subject: virtual hosts


Hi,

am trying to get name-based virtual hosting working.

here is my environment:
 windows 2000
 java jdk 1.4
 jakarta-tomcat-4.1.27-LE-jdk14.exe
 apache_2.0.47-win32-x86-no_ssl.msi
 jk2 connector
 oracle jdbc driver 9.x

Config for it is in Apache httpd.conf file, as follows:

#Virtual Hosting
NameVirtualHost [ip address here]

<VirtualHost www.me.com>
ServerName www.me.com
ServerAdmin [EMAIL PROTECTED]
#DocumentRoot "C:/Tomcat41/webapps/ROOT"
DocumentRoot /ROOT
ErrorLog "C:/apache2/Apache2/logs/me/error_log"
TransferLog "C:/apache2/Apache2/logs/me/access_log"
</VirtualHost>

<VirtualHost www.you.com>
ServerName www.you.com
ServerAdmin [EMAIL PROTECTED]
#DocumentRoot "C:/Tomcat41/webapps/you"
DocumentRoot /you
ErrorLog "C:/apache2/Apache2/logs/you/error_log"
TransferLog "C:/apache2/Apache2/logs/you/access_log"
</VirtualHost>

my problem is, regardless of which domain is typed into a browser, me.com or you.com, 
only me.com loads.

if anyone can help me out here, i need it.
thanks,
paul lomack

Reply via email to