Virtual Hosts In Tomcat

2005-08-25 Thread Dennis Harris
Hi,
 
I have Tomcat 4.1 running on Server 2003. Now I want to point a new
domain to this box using virtual hosts. I have read all the
documentation and I'm still unclear where in the server.xml file to
place this virtual host. Can someone paste an example of the virtual
hosts and where exactly in goes in the server.xml file.
 
Any help would be appreciated. By the way, I am a newbie with Tomcat.
 
Thanks.
 
D.


Re: Virtual Hosts In Tomcat

2005-08-25 Thread Hassan Schroeder

Dennis Harris wrote:


I have Tomcat 4.1 running on Server 2003. Now I want to point a new
domain to this box using virtual hosts. I have read all the
documentation and I'm still unclear where in the server.xml file to
place this virtual host. Can someone paste an example of the virtual
hosts and where exactly in goes in the server.xml file.


Grossly simplified, the hierarchy is:

Server
  Service
Connector/
Engine defaultHost=localhost
  Host name=localhost/
  Host name=dev.example.com/
  Host name=cool.example.com/
/Engine
  /Service
/Server


Any help would be appreciated. By the way, I am a newbie with Tomcat.


In which case, I'd recommend using a non-ancient release, i.e., one
in current active development; you'll get more and better responses
to your questions :-)

HTH,
--
Hassan Schroeder - [EMAIL PROTECTED]
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

  dream.  code.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Troubleshooting Virtual Hosts with Tomcat 5 standalone mode...

2005-04-04 Thread Jeff Duska
I'm trying to setup a couple of virtual hosts using Tomcat in stand
alone mode. I'm having a hell of a time to get this working correctly.
I've tried several configs, but they all fail.
I started with the goal of having a user directory for each virtual
host. For example, for the sample domain1.com the appbase would be
/home/domain/webapps.
I setup my server.xml file to have the following host settings
   Host name=domain1.com debug=0 appBase=/home/domain/webapps
   unpackWARs=true autoDeploy=true
   xmlValidation=false xmlNamespaceAware=false
Context path= docBase=./
/host
This is pretty much cut and past from Tomcat: The Definitive Guide from
Safari Online. This did not work. I would get just get a blank webpage.
I then tried to update the host file. I didn't see why I'd need to do
that since my DNS setup at Mydomain.com was working for ssh. I add
domain1.com to the line for my localhost. I restarted Tomcat. No change.
I am able to run the system on port 80 using just the localhost default
settings. I figured I just did something wrong. I switched to this
directions http://www.ex-parrot.com/~pete/tomcat-vhost.html
This didn't worked either. When I looked at the requests in in Safari,
it showed this as a bad request. I can telnet domain1.com 80. When I try
GET index.jsp or index,html or /. Nothing happens. No error. It just
closed the connection as if everything was working fine. I tried lynx
from the server prompt. It gives a http 400 error, I think. It flashes
by so fast I'm not sure.
The catalina.out has no errors.
I have my DNS setup via mydomain.com dns management tool. I have my A
record pointing to the address. I don't think I need to do anything else.
I'm at a loss of what to do now to troubleshoot this problem. I searched
the mail list and the website nothing has jumped out at me. So, I hoping
some kind soul might give me some pointers. What kills me is I'm sure
this is something obvious I missed or not seeing.
Thanks,
Jeff Duska
[EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Troubleshooting Virtual Hosts with Tomcat 5 standalone mode...

2005-04-04 Thread Hein Behrens
This is in my server.xml the directory is webapps/by-m.

It works also on a linux box. It is inside the engine.

 Host name=by-m debug=0 appBase=webapps unpackWARs=true
autoDeploy=true xmlValidation=false xmlNamespaceAware=false
Context path= docBase=by-m debug=5 reloadable=true
/Context
/Host
- Original Message - 
From: Jeff Duska [EMAIL PROTECTED]
To: tomcat-user@jakarta.apache.org
Sent: Monday, April 04, 2005 7:45 PM
Subject: Troubleshooting Virtual Hosts with Tomcat 5 standalone mode...


 I'm trying to setup a couple of virtual hosts using Tomcat in stand
 alone mode. I'm having a hell of a time to get this working correctly.
 I've tried several configs, but they all fail.

 I started with the goal of having a user directory for each virtual
 host. For example, for the sample domain1.com the appbase would be
 /home/domain/webapps.

 I setup my server.xml file to have the following host settings

 Host name=domain1.com debug=0 appBase=/home/domain/webapps
 unpackWARs=true autoDeploy=true
 xmlValidation=false xmlNamespaceAware=false
 Context path= docBase=./
 /host

 This is pretty much cut and past from Tomcat: The Definitive Guide from
 Safari Online. This did not work. I would get just get a blank webpage.

 I then tried to update the host file. I didn't see why I'd need to do
 that since my DNS setup at Mydomain.com was working for ssh. I add
 domain1.com to the line for my localhost. I restarted Tomcat. No change.

 I am able to run the system on port 80 using just the localhost default
 settings. I figured I just did something wrong. I switched to this
 directions http://www.ex-parrot.com/~pete/tomcat-vhost.html

 This didn't worked either. When I looked at the requests in in Safari,
 it showed this as a bad request. I can telnet domain1.com 80. When I try
 GET index.jsp or index,html or /. Nothing happens. No error. It just
 closed the connection as if everything was working fine. I tried lynx
 from the server prompt. It gives a http 400 error, I think. It flashes
 by so fast I'm not sure.

 The catalina.out has no errors.

 I have my DNS setup via mydomain.com dns management tool. I have my A
 record pointing to the address. I don't think I need to do anything else.

 I'm at a loss of what to do now to troubleshoot this problem. I searched
 the mail list and the website nothing has jumped out at me. So, I hoping
 some kind soul might give me some pointers. What kills me is I'm sure
 this is something obvious I missed or not seeing.

 Thanks,

 Jeff Duska
 [EMAIL PROTECTED]



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Troubleshooting Virtual Hosts with Tomcat 5 standalone mode...

2005-04-04 Thread Hassan Schroeder
Jeff Duska wrote:
I'm trying to setup a couple of virtual hosts using Tomcat in stand
alone mode.

I started with the goal of having a user directory for each virtual
host. For example, for the sample domain1.com the appbase would be
/home/domain/webapps.
I setup my server.xml file to have the following host settings
   Host name=domain1.com debug=0 appBase=/home/domain/webapps
   unpackWARs=true autoDeploy=true
   xmlValidation=false xmlNamespaceAware=false
Context path= docBase=./
/host
OK, don't do that :-)
Don't put the Context elements in server.xml. Put your Host elements
there, e.g.
   Host name=oahu  appBase=/www/oahu/Host
   Host name=maui  appBase=/www/maui/Host   
   Host name=kauai appBase=/www/kauai/Host  
Then (assuming you're using the default Engine name) make directories
   $CATALINA_HOME/conf/Catalina/oahu
   $CATALINA_HOME/conf/Catalina/maui
   $CATALINA_HOME/conf/Catalina/kauai
In each of those put your Context files, as in
   $CATALINA_HOME/conf/Catalina/oahu/ROOT.xml
   $CATALINA_HOME/conf/Catalina/oahu/manager.xml
   !-- the above if you want the manager app available --
   $CATALINA_HOME/conf/Catalina/oahu/cowabunga.xml
   !-- etc... --
which will look (minimally!) like
   Context docBase=/www/oahu/ROOT
!-- define Resources, etc. --   
   /Context 
That's it. Restart tomcat. Done. See, wasn't that easy? :-)
HTH!
--
Hassan Schroeder - [EMAIL PROTECTED]
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com
  dream.  code.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Running lots of virtual hosts on tomcat

2005-01-20 Thread Peter Rossbach
Hello,
that not really correct - see the german centaurus-platform 
http:/centaurus.sf.net/. We have build a little
tool hostcreator do to create host at runtime. You can build a new host 
with a template at runtime. Wait a week
than we release the 1.0beta6 with a integrated management application. 
Currently we  build the  Centaurus-Platform
with Tomcat 5.0.27 with some small modifcations.

One bad point:  We have wrote the complete documentation at german 
language. :-)  Sorry

Removing is a really problem. The internal JMX Api support a remove Host 
at memory but the config still exists at server.xml.
After restart your server the host is also restarted.
We hack the server.xml with a little some XSLT things, but we don't 
delete directories or files.

I hope we can discuss and implement a better way for tomcat 5.5. :-)
regards
Peter
Remy Maucherat schrieb:
On Wed, 19 Jan 2005 15:37:30 +0100, Robbert-Jan Roos [EMAIL PROTECTED] wrote:
 

Hi,
Our web department is thinking about moving from coldfusion to tomcat.
Currently we have about 400 websites using apache's mod_vhost module.
This works great. The only thing one needs to do is create a new
directory www.bla.nl and the website is up and running.
How would one do this in tomcat? I figured putting all the domainnames
in server.xml is not an option since it would require restarting
tomcat all the time. Using one Engine with a Context for each website
seems more usable.
Does anybody here have this kind of setup? Any pitfalls we might run
into? Suggestions?
   

Dynamic aadd/remove of hosts isn't supported through any tool at the
moment (= you have to build some kind of front end webapp and use the
Tomcat API to do it). I plan to add this in a future Tomcat 5.5 build.
 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Running lots of virtual hosts on tomcat

2005-01-19 Thread Robbert-Jan Roos
Hi,

Our web department is thinking about moving from coldfusion to tomcat.
Currently we have about 400 websites using apache's mod_vhost module.
This works great. The only thing one needs to do is create a new
directory www.bla.nl and the website is up and running.

How would one do this in tomcat? I figured putting all the domainnames
in server.xml is not an option since it would require restarting
tomcat all the time. Using one Engine with a Context for each website
seems more usable.

Does anybody here have this kind of setup? Any pitfalls we might run
into? Suggestions?

Regards,
Robbert-Jan Roos

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Running lots of virtual hosts on tomcat

2005-01-19 Thread Ben Souther
There are a few ways you could handle it.
This should get you started:
http://jakarta.apache.org/tomcat/tomcat-5.5-doc/deployer-howto.html


On Wed, 2005-01-19 at 09:37, Robbert-Jan Roos wrote:
 Hi,
 
 Our web department is thinking about moving from coldfusion to tomcat.
 Currently we have about 400 websites using apache's mod_vhost module.
 This works great. The only thing one needs to do is create a new
 directory www.bla.nl and the website is up and running.
 
 How would one do this in tomcat? I figured putting all the domainnames
 in server.xml is not an option since it would require restarting
 tomcat all the time. Using one Engine with a Context for each website
 seems more usable.
 
 Does anybody here have this kind of setup? Any pitfalls we might run
 into? Suggestions?
 
 Regards,
 Robbert-Jan Roos
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Running lots of virtual hosts on tomcat

2005-01-19 Thread Duong BaTien
Robbert-Jan Roos wrote:
Hi,
Our web department is thinking about moving from coldfusion to tomcat.
Currently we have about 400 websites using apache's mod_vhost module.
This works great. The only thing one needs to do is create a new
directory www.bla.nl and the website is up and running.
How would one do this in tomcat? I figured putting all the domainnames
in server.xml is not an option since it would require restarting
tomcat all the time. Using one Engine with a Context for each website
seems more usable.
Does anybody here have this kind of setup? Any pitfalls we might run
into? Suggestions?
 

Wow, you have a lot of websites. Portal may be an appropriate solution 
to consolidate contents. Description is in my previous post about 
Consolidate web applications.

BaTien
DBGROUPS
Regards,
Robbert-Jan Roos
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Running lots of virtual hosts on tomcat

2005-01-19 Thread Ronald Klop
RJ,
I think with a filter we can do our own version of mod_vhost.
But for reloading the classes/jsps it needs two instances of Tomcat (maybe on 
the same machine) with a loadbalancer to update one without interrupting the 
user.
Or is the compiler build into Tomcat 5.5 fast enough (and without memory leaks 
enough) to run it on a production machine.
Ronald.

On Wed Jan 19 15:37:30 CET 2005 Tomcat Users List tomcat-user@jakarta.apache.org wrote:
Hi,
Our web department is thinking about moving from coldfusion to tomcat.
Currently we have about 400 websites using apache's mod_vhost module.
This works great. The only thing one needs to do is create a new
directory www.bla.nl and the website is up and running.
How would one do this in tomcat? I figured putting all the domainnames
in server.xml is not an option since it would require restarting
tomcat all the time. Using one Engine with a Context for each website
seems more usable.
Does anybody here have this kind of setup? Any pitfalls we might run
into? Suggestions?
Regards,
Robbert-Jan Roos
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



deploying via ant, mutiple virtual hosts apache/tomcat

2004-07-22 Thread Dean A. Hoover
I have a named virtual host in apache that
uses mod_jk to communicate with tomcat.
I use ant/manager to deploy from my development
area, and everything works great. Now I've added
another named virtual host to apache and a new
worker for the tomcat connection. This works
great too, but not for deployment. How can I
get tomcat manager to differentiate between these
applications, since both of them are ROOT under
different directories. When I run manager through
HTML, I just see /. I can deploy my war by
hand and restart tomcat, but that is a pain.
Any ideas?
Dean Hoover
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Virtual Hosts on Tomcat 5

2004-07-03 Thread Marco Pöhler
Hi Steve,

just add an Alias directive nested in the Host-Element. An example can be 
seen in http://jakarta.apache.org/tomcat/tomcat-5.0-doc/config/host.html

hope that helps

Marco
---
http://www.optik-preisvergleich.de
http://www.druckerpatronen--preisvergleich.de
http://www.lenses-price-comparison.com

Am Freitag 02 Juli 2004 21:55 schrieb Steve Beaman:
 I'm using Tomcat 5 standalone.
 Everything works just fine, but now
 I need to enter my virtual hosts information
 in the server.xml file.

 Does anybody have a server.xml file
 that uses virtual hosts that I could use as an
 example?

 Thanks.

 ---
- Steve Beaman   [EMAIL PROTECTED]
 Altura International
 http://SHOP.COM
 http://www.catalogcity.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Virtual Hosts on Tomcat 5

2004-07-02 Thread Steve Beaman
I'm using Tomcat 5 standalone.
Everything works just fine, but now
I need to enter my virtual hosts information
in the server.xml file.

Does anybody have a server.xml file
that uses virtual hosts that I could use as an 
example?

Thanks.


Steve Beaman   [EMAIL PROTECTED]  
Altura International
http://SHOP.COM
http://www.catalogcity.com

Apache Virtual Hosts with Tomcat behind Localdirector

2003-11-20 Thread Dave Morrow
I have 2 Apache2 webservers each running multiple virtual hosts on different
ports (with a single IP address on each server) integrated with Tomcat using
mod_jk2

My Apache virtual hosting is setup as;

VirtualHost *:8000
ServerAdmin [EMAIL PROTECTED]
DocumentRoot /var/www/website1.mycompany.com
ServerName mywebsite1.mycompany.com
ErrorLog logs/mywebsite1.mycompany.com-error_log
CustomLog logs/mywebsite1.mycompany.com-access_log common
/VirtualHost
VirtualHost *:8001
ServerAdmin [EMAIL PROTECTED]
DocumentRoot /var/www/website2.mycompany.com
ServerName mywebsite2.mycompany.com
ErrorLog logs/mywebsite2.mycompany.com-error_log
CustomLog logs/mywebsite2.mycompany.com-access_log common
/VirtualHost

The configuration is working fine. For example, I can connect to
http://server1:8000/MyApp1 http://server1:8000/MyApp1  and
http://server2:8001/MyApp2 http://server2:8001/MyApp2 

I have configured the uri statements in the workers2.properties files such
that /MyApp1 is only accessible to the website on port 8000 as such;
[uri:*:8000/MyApp1/*]
[uri:*:8001/MyApp2/*]

Now, here is where I run into difficulties.  I am running a Cisco
Localdirector in front of these 2 webservers in order to provide port
mapping, load balancing etc.  For example, the local director receives
traffic on a virtual address (on port 80) and redirects traffic to the
appropriate web site (on a different port).  The problem is that the
Apache/Tomcat integration somehow breaks at this point (although pure http
traffic redirects properly).  I should mention here that if I configure a
webapp on the default virtual host in Apache, the re-direction through the
localdirector works fine.  It only breaks when I use a port based virtual
host in Apache.

If anyone else out there has done something similar, I would really
appreciate some assistance.

David Morrow
Systems Technical Lead, IT Operations
P: (519) 951-6079
F: (519) 451-6615
mailto: [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] 
 
..poor planning on your part does not make an emergency on my
part

 This message has originated from Autodata Solutions.  The attached material
is the Confidential and Proprietary Information of Autodata Solutions. This
email and any files transmitted with it are confidential and intended solely
for the use of the individual or entity to whom they are addressed. If you
have received this email in error please delete this message and notify the
Autodata system administrator at  [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] 




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Mapping Apache virtual hosts to Tomcat web applications

2003-10-29 Thread Patrick Herrera
Hi,

I am using mod_jk to connect Apache 1.3 to Tomcat 4.1.  I have the two
working together fine, but I want to know if I can map a specific virtual
host to a specific web application? In other words can I access 2 Tomcat
applications:

http://example.com:8080/greensite/index.jsp
http://example.com:8080/goldsite/index.jsp

as www.geensite.com/index.jsp and www.goldsite.com/index.jsp respectively?.
It appears that you can only map to the root of the Tomcat application
directory, meaning I will have to access them as
www.greensite.com/greensite/index.jsp for example.

I have looked through the HOWTO
(http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jk2/jk2/vhosthowto.html),
but I am beginning to suspect that this is only possible using JK2, and no
facility exists in JK for this level of control.

Is any of this possible using mod_jk?  Otherwise I may just look at
installing Apache 2 and mod_jk2 instead.

Thanks,

Patrick

Little Devil Media
Level 2 - 83 Salamanca Place,
Hobart, Tasmania
Australia 7004

Phone (+61 3) 6224 3535
Facsimile (+61 3) 6224 3545

Internet:  http://www.littledevil.com.au 



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Mapping Apache virtual hosts to Tomcat web applications

2003-10-29 Thread Oscar Carrillo
Yes you can.

I don't explicitly go into this, but I have some explanation on virtual
hosting with mapping to tomcat apps on my site with Apache
2.0/Tomcat/Mod_JK.

http://daydream.stanford.edu/tomcat/install_web_services.html

I'm sure you can find info in the archive here too.

Oscar

On Wed, 29 Oct 2003, Patrick Herrera wrote:

 Hi,
 
 I am using mod_jk to connect Apache 1.3 to Tomcat 4.1.  I have the two
 working together fine, but I want to know if I can map a specific virtual
 host to a specific web application? In other words can I access 2 Tomcat
 applications:
 
 http://example.com:8080/greensite/index.jsp
 http://example.com:8080/goldsite/index.jsp
 
 as www.geensite.com/index.jsp and www.goldsite.com/index.jsp respectively?.
 It appears that you can only map to the root of the Tomcat application
 directory, meaning I will have to access them as
 www.greensite.com/greensite/index.jsp for example.
 
 I have looked through the HOWTO
 (http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jk2/jk2/vhosthowto.html),
 but I am beginning to suspect that this is only possible using JK2, and no
 facility exists in JK for this level of control.
 
 Is any of this possible using mod_jk?  Otherwise I may just look at
 installing Apache 2 and mod_jk2 instead.
 
 Thanks,
 
 Patrick
 
 Little Devil Media
 Level 2 - 83 Salamanca Place,
 Hobart, Tasmania
 Australia 7004
 
 Phone (+61 3) 6224 3535
 Facsimile (+61 3) 6224 3545
 
 Internet:  http://www.littledevil.com.au 
   
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



virtual hosts in tomcat

2003-09-29 Thread Johan Louwers
Virtual Hosts in tomcat 
how do you handel virtual hosts in tomcat?

I have in Apache (httpd) 2 virtual hosts www.someserver.com and mnt.someserver.com I 
would like to run on both jsp pages how do I make this work?

Regards,
Johan.


Re: virtual hosts in Tomcat and Apache

2003-07-15 Thread John Turner
Yes, in general you need a VirtualHost in httpd.conf for all virtual hosts 
in server.xml.  Otherwise, AFAIK, Tomcat will use the defaultHost defined 
in the Engine container, which is typically set to localhost by default.

John

On Tue, 15 Jul 2003 13:17:03 +1000, [EMAIL PROTECTED] wrote:

Hi again, Apache2+Tomcat+mod_jk working find until...
I used a virtual host directive in server.xml, that's fine; but
When I start adding virtual hosts in Apache, one for each developer's
directory, I got following error message :

RemoteORAClient: set URL to http://www.myhost.com/myhost/RemoteORAServer
java.io.FileNotFoundException:
http://www.myhost.com/myhost/RemoteORAServer
at sun.net.www.protocol ...bla

As soon as I remove the virtual host directives in APACHE2, all okay
again.
I am beginning to wonder whether I need a corresponding virtual host in
Server.xml for each virtual host in Apache2 ???
Where do I start with this problem, I coded the a2s and I don't remember
hardcoding any FQDN anywhere... ???
But errare humanum est


--
Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


virtual hosts in Tomcat and Apache

2003-07-14 Thread achana
Hi again, Apache2+Tomcat+mod_jk working find until...
I used a virtual host directive in server.xml, that's fine; but
When I start adding virtual hosts in Apache, one for each developer's
directory, I got following error message :

RemoteORAClient: set URL to http://www.myhost.com/myhost/RemoteORAServer
java.io.FileNotFoundException:
http://www.myhost.com/myhost/RemoteORAServer
at sun.net.www.protocol ...bla

As soon as I remove the virtual host directives in APACHE2, all okay
again.
I am beginning to wonder whether I need a corresponding virtual host in
Server.xml for each virtual host in Apache2 ???
Where do I start with this problem, I coded the a2s and I don't remember
hardcoding any FQDN anywhere... ???
But errare humanum est
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

mod_jk or mod_jk2 or mod_webapp for virtual hosts on tomcat.

2002-09-20 Thread Eugene Gluzberg


Hi,

I am planning to link VirtualHosts under apache 1.3 to different tomcat 
servers (all tomcat 4.1.10) runnning on different machines. I am 
planning to link vhost1 to tomcat1, and vhost2 to tomcat2, etc...

Should I user mod_jk2, or mod_jk or mod_webapp for this? which is 
better, and easier to configure?

I looked up a thread 
http://www.mail-archive.com/tomcat-user@jakarta.apache.org/msg66461.html 
to see if anyone has done what i will soon be trying, but it seems they 
did not get it to work yet...

Clues, how tos would be helpful

Eugene


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Directory layout - virtual hosts in tomcat

2002-09-18 Thread Glenn Nielsen

I also use mod_jk 1.2 with virtual hosting and allow the appBase
for Tomcat to be the document root for apache.

I use JkAutoAlias.  It will automatically serve static files for
any webapp and return a 403 error if someone tries to access
a webapps /WEB-INF or /META-INF directories.

See the docs here and search for JkAutoAlias:

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jk2/jk/aphowto.html

This works great for me.

Regards,

Glenn

mdevin wrote:
 Hi all,
 
 I am looking for some advice regarding the usual directory layout for
 Virtual Hosts and tomcat.
 
 Currently I have a working setup of apache and tomcat using mod_jk.  I
 have set things up the way that tomcat seems to prefer (or what others
 seem to have done based on the documentation I could find).
 
 Essentially, I have apache and tomcat both using the same document root
 so that apache will serve any static html pages and tomcat will do the
 jsp and servlet stuff.  However, I am concerned that from a security
 point of view, this may not be the best option.  In particular, this
 means that my cgi-bin directory comes below my document root and I have
 to explicitely deny access to the WEB-INF directory.
 
 Anyway, I am a little confused as to the best way to go in terms of
 security and at the same time most easily separable into Virtual Hosts
 so that different people can work on their own projects without
 interfering with others.
 
 Any suggestions welcome.  In particular, I am interested in how others
 have set up virtual hosts for tomcat.
 
 Regards.
 Mark.
 
 Currently each of my Virtual Hosts has the following directory layout:
 
 /www/hostname/- all static html files
   - also appBase to tomcat host
  /cgi-bin/- perl cgi scripts etc.
 
 I have configured Virtual hosts like follows in apache:
 ... cut ...
 VirtualHost *
 ServerName www.myhost.com
 ServerAdmin [EMAIL PROTECTED]
 DocumentRoot /www/myhost
 JKMount /servlet/* ajp13
 JKMount /*.jsp ajp13
 Directory /www/myhost/
 AllowOverride None
 Options Indexes
 Order Deny,Allow
 Allow from all
 /Directory
 ScriptAlias /cgi-bin/ /www/myhost/cgi-bin/
 Directory /www/myhost/cgi-bin/
 Allow from all
 Options ExecCGI
 /Directory
 Location /WEB-INF/
 deny from all
 /Location
 Location /META-INF/
 deny from all
 /Location
 /VirtualHost
 
 And I have the following in my server.xml file:
  ... cut ...
   Service name=Tomcat-Apache
 
 Connector className=org.apache.ajp.tomcat4.Ajp13Connector
   port=8009 minProcessors=5 maxProcessors=75
   enableLookups=true acceptCount=10 debug=0/
 
 Engine name=Tomcat-Apache defaultHost=localhost debug=0
 
   Logger className=org.apache.catalina.logger.FileLogger
 prefix=catalina_log. suffix=
 timestamp=true/
 
   Realm className=org.apache.catalina.realm.MemoryRealm /
 
   ......
   ... snip localhost section ...
   ......
 
   !-- www.myhost.com VirtualHost --
   Host name=www.multistep.info debug=0 unpackWARs=false
 
 Valve className=org.apache.catalina.valves.AccessLogValve
   directory=logs  prefix=myhost_access_log. suffix=
   pattern=common /
 
 Logger className=org.apache.catalina.logger.FileLogger
   directory=logs  prefix=myhost_log. suffix=
   timestamp=true/
 
 Context path= docBase=/www/myhost
   crossContext=false debug=0 reloadable=true /
 
   /Host
 /Engine
   /Service
 /Server




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Directory layout - virtual hosts in tomcat

2002-09-17 Thread mdevin

Hi all,

I am looking for some advice regarding the usual directory layout for
Virtual Hosts and tomcat.

Currently I have a working setup of apache and tomcat using mod_jk.  I
have set things up the way that tomcat seems to prefer (or what others
seem to have done based on the documentation I could find).

Essentially, I have apache and tomcat both using the same document root
so that apache will serve any static html pages and tomcat will do the
jsp and servlet stuff.  However, I am concerned that from a security
point of view, this may not be the best option.  In particular, this
means that my cgi-bin directory comes below my document root and I have
to explicitely deny access to the WEB-INF directory.

Anyway, I am a little confused as to the best way to go in terms of
security and at the same time most easily separable into Virtual Hosts
so that different people can work on their own projects without
interfering with others.

Any suggestions welcome.  In particular, I am interested in how others
have set up virtual hosts for tomcat.

Regards.
Mark.

Currently each of my Virtual Hosts has the following directory layout:

/www/hostname/  - all static html files
- also appBase to tomcat host
 /cgi-bin/  - perl cgi scripts etc.

I have configured Virtual hosts like follows in apache:
... cut ...
VirtualHost *
ServerName www.myhost.com
ServerAdmin [EMAIL PROTECTED]
DocumentRoot /www/myhost
JKMount /servlet/* ajp13
JKMount /*.jsp ajp13
Directory /www/myhost/
AllowOverride None
Options Indexes
Order Deny,Allow
Allow from all
/Directory
ScriptAlias /cgi-bin/ /www/myhost/cgi-bin/
Directory /www/myhost/cgi-bin/
Allow from all
Options ExecCGI
/Directory
Location /WEB-INF/
deny from all
/Location
Location /META-INF/
deny from all
/Location
/VirtualHost

And I have the following in my server.xml file:
 ... cut ...
  Service name=Tomcat-Apache

Connector className=org.apache.ajp.tomcat4.Ajp13Connector
  port=8009 minProcessors=5 maxProcessors=75
  enableLookups=true acceptCount=10 debug=0/

Engine name=Tomcat-Apache defaultHost=localhost debug=0

  Logger className=org.apache.catalina.logger.FileLogger
prefix=catalina_log. suffix=
timestamp=true/

  Realm className=org.apache.catalina.realm.MemoryRealm /

  ......
  ... snip localhost section ...
  ......

  !-- www.myhost.com VirtualHost --
  Host name=www.multistep.info debug=0 unpackWARs=false

Valve className=org.apache.catalina.valves.AccessLogValve
  directory=logs  prefix=myhost_access_log. suffix=
  pattern=common /

Logger className=org.apache.catalina.logger.FileLogger
  directory=logs  prefix=myhost_log. suffix=
  timestamp=true/

Context path= docBase=/www/myhost
  crossContext=false debug=0 reloadable=true /

  /Host
/Engine
  /Service
/Server



msg66027/pgp0.pgp
Description: PGP signature


Seting Classpath for Virtual Hosts with Tomcat 3.3.1

2002-09-06 Thread Joshua D. Drake

Hello,

  I am running RedHat 7.3, Apache 1.3.26 and Tomcat-3.3.1. I am having 
problems getting Tomcat to pick up new
classpaths for virtual hosts. We can successfully run jsp files from the 
virtual hosts but once we try to add a class
(for JavaBeans in this case) it fails.

  Here is my apps-vhosts.xml:

  ?xml version=1.0 encoding=ISO-8859-1?
Server
 Host name=dev.sflsoccer.us
  Context path=
docBase=/home/vhosting/sfl/htdocs/
debug=5
/
 /Host
/Server

Also I have the following lines in my tomcat.properties:

wrapper.path=/bin:/usr/bin:/usr/local/bin:/home/vhosting/sfl/bin:/usr/java/j2sdk1.4.0_01/bin
wrapper.classpath=@JSERV_CLASSES@:@JSDK_CLASSES@:/home/vhosting/sfl/htdocs

Normally I would call to a separate class directory but I am just trying 
to get it to work at this point.
I also added the following to my tomcat3.conf although it is my 
understanding that tomcat3 doesn't
care about shell variables for the classpath:

CLASSPATH=/home/vhosting/sfl/htdocs/classes:/home/vhostings/sfl/htdocs
export CLASSPATH

Help would be greatly appreciated,

Sincerely,

Joshua D. Drake










--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Virtual Hosts and Tomcat.

2002-04-15 Thread Antonio MATTA


Hi,

I am a newbie with Tomcat. I manage a server that runs both apache and
tomcat.
I have been looking a good Howto with wich I can learn how to set virtual
hosts using Tomcat: which modules do I have to set? Which configure files
do I have to edit?

Any help will be apreciated,

Antonio.

-- 
ANTONIO ALEJANDRO MATTA GÓMEZ
WebMaster
Facultad de Ingeniería
Pontificia Universidad Javeriana - Seccional Cali
Calle 18 No. 118 - 250 Av. Cañasgordas
Cali, Colombia
Tel. (+2)  3218200 Ext 575
Fax. 5552823




--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Re: Virtual Hosts and Tomcat.

2002-04-15 Thread Gregory Moxley Kempster

This looks pretty good for mod_webapp:

http://dcb.sun.com/practices/howtos/tomcat_apache.jsp

Gregory Moxley Kempster
FastTrack Designs
http://www.fasttrackdesigns.com
503-452-3721

- Original Message -
From: Antonio MATTA [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, April 15, 2002 2:09 PM
Subject: Virtual Hosts and Tomcat.



 Hi,

 I am a newbie with Tomcat. I manage a server that runs both apache and
 tomcat.
 I have been looking a good Howto with wich I can learn how to set virtual
 hosts using Tomcat: which modules do I have to set? Which configure files
 do I have to edit?

 Any help will be apreciated,

 Antonio.

 --
 ANTONIO ALEJANDRO MATTA GÓMEZ
 WebMaster
 Facultad de Ingeniería
 Pontificia Universidad Javeriana - Seccional Cali
 Calle 18 No. 118 - 250 Av. Cañasgordas
 Cali, Colombia
 Tel. (+2)  3218200 Ext 575
 Fax. 5552823




 --
 To unsubscribe:   mailto:[EMAIL PROTECTED]
 For additional commands: mailto:[EMAIL PROTECTED]
 Troubles with the list: mailto:[EMAIL PROTECTED]





--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




How to setup multi-virtual hosts on tomcat 4.0 and apache 1.3

2002-02-04 Thread Thanh Duong

Hi,
I am trying to setup multi virtual hosts on tomcat 4.0 and apache 1.3. I
don't know what I did wrong, but it doesn't work.
When I try to call http;//example1.de/index.jsp, it said
The requested resource (/index.jsp) is not available.

Does someone know how to setup virtual hosts correctly?

Thanks
Thanh


I did the following:

in httpd.conf:
NameVirtualHost 1.2.1.211
VirtualHost 1.2.1.211
   DocumentRoot /example1.de
   ServerName example1.de
   ServerPath /example1.de/
   ErrorLog logs/example1-error_log
   CustomLog logs/example1-access_log common
/VirtualHost

VirtualHost 1.2.1.211
   DocumentRoot /example2.de
   ServerName example2.de
   ServerPath /example2.de/
   ErrorLog logs/example2.at-error_log
   CustomLog logs/example2.at-access_log common
/VirtualHost

in server.xml:

Engine name=Standalone defaultHost=localhost debug=0

!-- Define the default virtual host --
Host name=localhost debug=0 appBase=webapps unpackWARs=true
Context path=/manager docBase=manager
 debug=0 privileged=true/
   Context path=/iw-mount/default/main/Development/WORKAREA
 docBase=/.iwmnt/default/main/Development/WORKAREA
 crossContext=false
 debug=0
 reloadable=true 
/Context
...
/Host

Host name=example1.de appBase=/example1.de debug=0
Context path=/static_js
 docBase=/example1.de/static_js
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context

Context path=
 docBase=/example1.de
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context
/Host

Host name=example2.de appBase=/example1.de debug=0
Context path=/static_js
 docBase=/example2.de/static_js
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context

Context path=
 docBase=/example2.de
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context
/Host
/Engine


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




FW: How to setup multi-virtual hosts on tomcat 4.0 and apache 1.3

2002-02-04 Thread Thanh Duong



-Original Message-
From: Thanh Duong [mailto:[EMAIL PROTECTED]]
Sent: Montag, 4. Februar 2002 19:55
To: Tomcat Users List
Subject: How to setup multi-virtual hosts on tomcat 4.0 and apache 1.3


Hi,
I am trying to setup multi virtual hosts on tomcat 4.0 and apache 1.3. I
don't know what I did wrong, but it doesn't work.
When I try to call http;//example1.de/index.jsp, it said
The requested resource (/index.jsp) is not available.

Does someone know how to setup virtual hosts correctly?

Thanks
Thanh


I did the following:

in httpd.conf:
NameVirtualHost 1.2.1.211
VirtualHost 1.2.1.211
   DocumentRoot /example1.de
   ServerName example1.de
   ServerPath /example1.de/
   ErrorLog logs/example1-error_log
   CustomLog logs/example1-access_log common
/VirtualHost

VirtualHost 1.2.1.211
   DocumentRoot /example2.de
   ServerName example2.de
   ServerPath /example2.de/
   ErrorLog logs/example2.at-error_log
   CustomLog logs/example2.at-access_log common
/VirtualHost

in server.xml:

Engine name=Standalone defaultHost=localhost debug=0

!-- Define the default virtual host --
Host name=localhost debug=0 appBase=webapps unpackWARs=true
Context path=/manager docBase=manager
 debug=0 privileged=true/
   Context path=/iw-mount/default/main/Development/WORKAREA
 docBase=/.iwmnt/default/main/Development/WORKAREA
 crossContext=false
 debug=0
 reloadable=true 
/Context
...
/Host

Host name=example1.de appBase=/example1.de debug=0
Context path=/static_js
 docBase=/example1.de/static_js
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context

Context path=
 docBase=/example1.de
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context
/Host

Host name=example2.de appBase=/example1.de debug=0
Context path=/static_js
 docBase=/example2.de/static_js
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context

Context path=
 docBase=/example2.de
 crossContext=false
 debug=0
 override=true
 reloadable=true 
/Context
/Host
/Engine


--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




Possible to have multiple SSL enabled virtual hosts with Tomcat 4 in standalone mode?

2001-12-18 Thread Jonathan Eric Miller

I'm wondering if anyone knows if it is possible to have multiple virtual
hosts in Tomcat 4 standalone mode, each with a SSL enabled?

If so, do I need to somehow put more than one host name into the SSL
certificate? Or, is there a way to install multiple SSL certificates?

So, for example, say I have the following setup.

myhostname.mydomain.com
mycname1.mydomain.com
mycname2.mydomain.com

I have virtual hosts setup for mycname1 and mycname2. Would I need a
certificate for each of these virtual hosts? Or, would I have a single
certificate with two host names in it? Or, am I confused?

Jon



--
To unsubscribe:   mailto:[EMAIL PROTECTED]
For additional commands: mailto:[EMAIL PROTECTED]
Troubles with the list: mailto:[EMAIL PROTECTED]




virtual hosts with Tomcat 3.2.2 Apache 1.3.20

2001-07-09 Thread Gary Dale

I've got 3.2.2 to work and I've integrated it with Apache. I can run the 
example applications as either http://server:8080/ or http://server/ and 
they work.

Some consultants have developed some java applications that I need to 
install on this server. They don't seem to have followed the standards 
however. There are no web.xml files for the applications, for example. 
Instead the application files are just stored in subdirectories of 
webapps, except for shared components which are in subdirectories of 
tomcat_home/classes.

The applications work when I run them as http://server/appname/ but I 
need to get them to run as http://appname.domain.dom/. When I set up the 
virtual hosts for these applicaitons however, I run into problems. I get 
the error message:


  Error: 500


Location: /index.jsp

*Internal Servlet Error:*

java.lang.NullPointerException
at org.apache.tomcat.util.FileUtil.isAbsolute(FileUtil.java:289)
at org.apache.tomcat.core.Context.getAbsolutePath(Context.java:257)
at org.apache.tomcat.core.Context.getRealPath(Context.java:794)
at 
org.apache.tomcat.facade.ServletContextFacade.getRealPath(ServletContextFacade.java:136)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:490)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)
at org.apache.tomcat.core.Handler.service(Handler.java:287)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at 
org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:797)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:743)
at 
org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection(Ajp12ConnectionHandler.java:166)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
at java.lang.Thread.run(Thread.java:484)

Any idea on what is going wrong?




Virtual Hosts and Tomcat 3.2.1/IIS

2001-05-14 Thread Ross Merritt

We're currently trying to configure a server with one Tomcat NT service and
the following contexts in server.xml:

  host name=127.0.0.1
Context path=/examples
 docBase=webapps/examples 
 crossContext=false
 debug=0 
 reloadable=true  
/Context
  /host



host name=dcm.someone.net
context path=/cbastaging
docBase=e:/dcm
crossContext=false
debug=0
reloadable=true 
/context
/host

We can't get anything to work .jsp-wise except webapps\examples, and they
work in both virtual hosts.  The best we've been able to do is see the .jsp
code in the dcm..net host; no execute.  We're using Tomcat 3.2.1; what might
we be missing?

Glenn Butcher sends...




[Fwd: Multiple IP based virtual hosts in Tomcat 4]

2001-04-23 Thread Neil Aggarwal

Hello:

Has anyone seen this problem

Thanks,
Neil.

--
Neil Aggarwal
JAMM Consulting, Inc. -- (972) 612-6056, http://www.JAMMConsulting.com
Custom Internet Development -- Java, JSP, servlets, databases


Hello:

I am trying to set-up multiple IP based virtual hosts in 
Tomcat 4.0 Beta 3 running as a Standalone container.

I downloaded the 4.0b3 binary of tomcat, dearchived it,
and modified the following items in the server.xml
file:

In the Service name=Tomcat-Standalone section,
I changed the HttpConnector to use port 80 so that
it would respond to normal web requests.

In the Engine section, below the Host section for localhost,
I added the following lines:
  Host name=xxx.xxx.xxx.xxx debug=1 appBase=webapps
unpackWARs=true
Context path= docBase=host1
/Context
  /Host

  Host name=yyy.yyy.yyy.yyy debug=1 appBase=webapps
unpackWARs=true
Context path= docBase=host2
/Context
  /Host

Then, I started tomcat.  When I visit http://xxx.xxx.xxx.xxx,
I get the index.jsp file from the host1 directory as expected.

But when I visit http://yyy.yyy.yyy.yyy, I get this message:
HTTP Status 503 - This application is not currently
available

The requested service (This application is not currently available) is
not currently available. 

Any idea why this is occurring?

Thanks,
Neil.

--
Neil Aggarwal
JAMM Consulting, Inc. -- (972) 612-6056, http://www.JAMMConsulting.com
Custom Internet Development -- Java, JSP, servlets, databases





RE: [Fwd: Multiple IP based virtual hosts in Tomcat 4]

2001-04-23 Thread Danny Angus

Context path=
should probably be
Context path=/
too

 -Original Message-
 From: Neil Aggarwal [mailto:[EMAIL PROTECTED]]
 Sent: Monday, April 23, 2001 5:17 PM
 To: tomcat users list
 Subject: [Fwd: Multiple IP based virtual hosts in Tomcat 4]
 
 
 Hello:
 
 Has anyone seen this problem
 
 Thanks,
   Neil.
 
 --
 Neil Aggarwal
 JAMM Consulting, Inc. -- (972) 612-6056, http://www.JAMMConsulting.com
 Custom Internet Development -- Java, JSP, servlets, databases



Re: [Fwd: Multiple IP based virtual hosts in Tomcat 4]

2001-04-23 Thread Neil Aggarwal

Danny:

I change my tomcat 4 server.xml file to:
  Host name=xxx.xxx.xxx.xxx debug=1 appBase=webapps
unpackWARs=true
Context path=/ docBase=host1
/Context
  /Host

  Host name=yyy.yyy.yyy.yyy debug=1 appBase=webapps
unpackWARs=true
Context path=/ docBase=host2
/Context
  /Host

When I got to xxx.xxx.xxx.xxx, I get:
HTTP Status 404 - /index.jsp

The requested resource (/index.jsp) is not available. 

When I go to yyy.yyy.yyy.yyy, I get nothing, the browser 
just sits there and loads nothing. Eventually, it times out.

Any more ideas?

Thanks,
Neil.

Danny Angus wrote:
 
 Context path=
 should probably be
 Context path=/
 too
 
  -Original Message-
  From: Neil Aggarwal [mailto:[EMAIL PROTECTED]]
  Sent: Monday, April 23, 2001 5:17 PM
  To: tomcat users list
  Subject: [Fwd: Multiple IP based virtual hosts in Tomcat 4]
 
 
  Hello:
 
  Has anyone seen this problem
 
  Thanks,
Neil.
 
  --
  Neil Aggarwal
  JAMM Consulting, Inc. -- (972) 612-6056, http://www.JAMMConsulting.com
  Custom Internet Development -- Java, JSP, servlets, databases

--
Neil Aggarwal
JAMM Consulting, Inc. -- (972) 612-6056, http://www.JAMMConsulting.com
Custom Internet Development -- Java, JSP, servlets, databases



Multiple IP based virtual hosts in Tomcat 4

2001-04-19 Thread Neil Aggarwal

Hello:

I am trying to set-up multiple IP based virtual hosts in 
Tomcat 4.0 Beta 3 running as a Standalone container.

I downloaded the 4.0b3 binary of tomcat, dearchived it,
and modified the following items in the server.xml
file:

In the Service name="Tomcat-Standalone" section,
I changed the HttpConnector to use port 80 so that
it would respond to normal web requests.

In the Engine section, below the Host section for localhost,
I added the following lines:
  Host name="xxx.xxx.xxx.xxx" debug="1" appBase="webapps"
unpackWARs="true"
Context path="" docBase="host1"
/Context
  /Host

  Host name="yyy.yyy.yyy.yyy" debug="1" appBase="webapps"
unpackWARs="true"
Context path="" docBase="host2"
/Context
  /Host

Then, I started tomcat.  When I visit http://xxx.xxx.xxx.xxx,
I get the index.jsp file from the host1 directory as expected.

But when I visit http://yyy.yyy.yyy.yyy, I get this message:
HTTP Status 503 - This application is not currently
available

The requested service (This application is not currently available) is
not currently available. 

Any idea why this is occurring?

Thanks,
Neil.

--
Neil Aggarwal
JAMM Consulting, Inc. -- (972) 612-6056, http://www.JAMMConsulting.com
Custom Internet Development -- Java, JSP, servlets, databases



Re: Virtual Hosts w/ Tomcat+Apache

2001-03-12 Thread tomcat

It's something like this:

server.xml:

Host name="www.domain.com"
  Context path="" docBase="/home/someone/web/app" debug="0"/
/Host
Host name="domain.com"
  Context path="" docBase="/home/someone/web/app" debug="0"/
/Host


httpd.conf:

VirtualHost multihost.maindomain.com:80
   ServerName www.domain.com
   ServerAlias domain.com
   DocumentRoot /home/someone/web/app

Directory  "/home/someone/web/app"

Options ExecCGI Indexes Includes FollowSymLinks MultiViews
AllowOverride AuthConfig FileInfo Indexes Limit Options
Order allow,deny
Allow from all

/Directory


IfModule mod_jk.c
  JkWorkersFile /opt/tomcat/conf/workers.properties
  JkLogFile /opt/tomcat/logs/mod_jk.log

  #
  # Log level to be used by mod_jk
  #
  JkLogLevel error

  JkMount /*.jsp ajp13
  JkMount /servlet/* ajp13
/IfModule


/VirtualHost




On Sun, 11 Mar 2001, Joshua Lifton wrote:

 
 The "Tomcat-Apache HOWTO" document that comes with the Tomcat 3.2.1 distro
 mentions that there are two different ways to configure Tomcat for virtual
 hosts; one is to use a different Tomcat for each Apache virtual host and
 the other is to use the same Tomcat for each Apache virtual host.  In the
 case of the latter, the HOWTO file mentions that Apache's httpd.conf file
 must be configured using the VirtualHost directive and gives an example
 of such.  In addition, the HOWTO file states that Tomcat's server.xml must
 be configured using the Host directive.  An example is given for this as
 well, but it is identical to the example given for the VirtualHost
 directive in the httpd.conf file.  Is this a typo?  I checked the
 server.xml file and found a rough sketch of the Host directive being
 used for working with virtual hosts, but would like to see a more complete
 example.  Anybody have experience with this?  If it is a typo, how
 do we go about fixing it?  Thanks, josh
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, email: [EMAIL PROTECTED]
 
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Virtual Hosts w/ Tomcat+Apache

2001-03-11 Thread Joshua Lifton


The "Tomcat-Apache HOWTO" document that comes with the Tomcat 3.2.1 distro
mentions that there are two different ways to configure Tomcat for virtual
hosts; one is to use a different Tomcat for each Apache virtual host and
the other is to use the same Tomcat for each Apache virtual host.  In the
case of the latter, the HOWTO file mentions that Apache's httpd.conf file
must be configured using the VirtualHost directive and gives an example
of such.  In addition, the HOWTO file states that Tomcat's server.xml must
be configured using the Host directive.  An example is given for this as
well, but it is identical to the example given for the VirtualHost
directive in the httpd.conf file.  Is this a typo?  I checked the
server.xml file and found a rough sketch of the Host directive being
used for working with virtual hosts, but would like to see a more complete
example.  Anybody have experience with this?  If it is a typo, how
do we go about fixing it?  Thanks, josh


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




Virtual hosts on Tomcat 3.2

2001-02-09 Thread Chris Freyer

Hi all, new subscriber here.  I'm running Tomcat
stand-alone.  I upgraded to 3.2 last night for the
multiple host support.

Several questions
Can I have separate logfiles for each host?
Can separate hosts share a context? (just curious).
Can sessions be shared between hosts?
Can database connections be pooled across hosts?
What problems will I run into if one host's path is a
subdirectory of another's?

Thanks, and please point me in the right direction if
these Q's have been answered already.

Chris

=
-
Chris Freyer  | 4-BR/2-BA Home For Sale in
Software Engineer | Jacksonville, FL.  Visit [EMAIL PROTECTED] | 
http://www.freyer.homeip.net

__
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]




virtual hosts on tomcat 4.0-m5

2000-12-16 Thread Christian Parpart

Hi

I thought about installing a virtual host in Tomcat/4.0-m5 (standalone
mode).
But, I just can type appBase="webapps" and not anything else.
Is That the right way to do that?

Please help, the online help can't.

server.xml
-

  Host name="www.myhost.tld"
appBase="c:\www\myhost\htdocs"


Valve className="org.apache.catalina.valves.AccessLogValve"
 directory="logs"  prefix="myhost_access_log" suffix=".txt"
 pattern="common"/

Logger className="org.apache.catalina.logger.FileLogger"
directory="logs"  prefix="myhost_log" suffix=".txt"
  timestamp="true"/

  /Host

--

Regards,
Christian Parpart mailto:[EMAIL PROTECTED]
SurakWare
http://www.surakware.com




Re: virtual hosts on tomcat 4.0-m5

2000-12-16 Thread Craig R. McClanahan

Christian Parpart wrote:

 Hi

 I thought about installing a virtual host in Tomcat/4.0-m5 (standalone
 mode).
 But, I just can type appBase="webapps" and not anything else.
 Is That the right way to do that?


Yes, you can do this (set "appBase" to some directory location.  Tomcat will
look inside this directory for contexts to be deployed automatically, just like
it does in the "webapps" directory in the default configuration.

If you wanted the "htdocs" directory in your example to be the root context for
this virtual host, you might want to rename it to "ROOT" and set things up like
this:


Host name="www.myhost.tld" appBase="c:\www\myhost"
... preferred valves, loggers, etc. ...
/Host

or, alternatively, you can put an absolute pathname on a Context entry:

Host name="www.myhost.tld" appBase="... arbitrary value ..."
... preferred valves, loggers, etc. ...
Context path="" docBase="c:\www\myhost\htdocs" ... /
/Host


 Please help, the online help can't.


Craig McClanahan



 server.xml
 -
 
   Host name="www.myhost.tld"
 appBase="c:\www\myhost\htdocs"
 

 Valve className="org.apache.catalina.valves.AccessLogValve"
  directory="logs"  prefix="myhost_access_log" suffix=".txt"
  pattern="common"/

 Logger className="org.apache.catalina.logger.FileLogger"
 directory="logs"  prefix="myhost_log" suffix=".txt"
   timestamp="true"/

   /Host
 
 --

 Regards,
 Christian Parpart mailto:[EMAIL PROTECTED]
 SurakWare
 http://www.surakware.com




Security and virtual hosts on Tomcat 3.2

2000-12-08 Thread Nirav S. Desai

Hi,
I am trying to set up a secure tomcat/apache server. I have Apache set up with
mod_ssl and tomcat 3.2 setup with viruatl hosts. All of this works great. However, I am
haveing trouble getting the secure and insecure  hosts to map to different pages in
tomcat. That is, I want "http://www.host1.com" to map to directory A and
"https://www.host1.com"  map to directory B. Does anyone know how to do this? Thanks in
advance.

Nirav Desai




Virtual Hosts under Tomcat

2000-11-16 Thread Todd Davis

As I was perusing the Tomcat-Apache HOWTO, I have run across what I
believe to be a slight discrpency.  In the discussion about configuring
Virtual Hosts using the same Tomcat VM for all Virtual Hosts,the example
provided for httpd.conf and the example for server.xml are exactly the
same.  I'm assuming that the server.xml example is the wrong one and the
example should have Host tags rather than VirtualHost.  Does anyone
have the correct example for server.xml?
-- 
-
Todd J. Davis
Internet Consultant

MSFW Consulting
3445 Liberty Drive
Springfield, IL  62704
217-698-3535
=