RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-19 Thread Larry Isaacs

There is a little documentation about this, which is found
at the following online locations.

Context configuration:

<http://jakarta.apache.org/tomcat/tomcat-3.3-doc/tomcat-ug.html#context_addcust>

Apache mod_jk.conf generation:

<http://jakarta.apache.org/tomcat/tomcat-3.3-doc/serverxml.html#ApacheConfig>

The result is that a virtual host configuration like:









results in the following in the conf/auto/mod_jk.conf
generated by the ApacheConfig module:

NameVirtualHost xx.xx.xx.xxx

ServerName virtual.host.name
ServerAlias virtual.host.alias 

JkMount /myapp ajp13
JkMount /myapp/* ajp13


When a request comes into Apache for this virtual host,
mod_jk will include the ServerName, "virtual.host.name",
in the forwarded request.  On the Tomcat 3.3 side, this
server name is used in the mapping so that the request
will only map against contexts defined for that virtual
host.  What I don't know is how the ServerName value
would be used by Tomcat 4.x.  It might have the same
effect for virtual hosts configured in Tomcat 4.x, but
I haven't investigated this yet.

Future connector work is happening in the
jakarta-tomcat-connectors project.  Bill Barker has
added org.apache.ajp.tomcat4.config.ApacheConfig and
others to jakarta-tomcat-connectors/jk/java, so there
will likely be something available in Tomcat 4.0.2
and Tomcat 4.1 when they are released.

Cheers,
Larry

> -Original Message-
> From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 18, 2001 4:02 PM
> To: Tomcat Users List
> Subject: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs
> 
> 
> Larry,
> 
> Perhaps if you provide your Tomcat 3.3 solution(s), we could 
> see how they
> might apply to Tomcat 4?
> 
> Whom would know Tomcat 4?
> 
>   --- Noel
> 
> -Original Message-
> From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> 
> Hi Noel,
> 
> Unfortunately my knowledge of Tomcat 4.x internals is still fairly
> limited, so I can't be of much help at this point in time.  My
> primary experience in this area was getting a suitable
> conf/auto/mod_jk generated by Tomcat 3.3 when using virtual hosts.
> 
> Cheers,
> Larry
> 
> > -Original Message-
> > From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, December 18, 2001 3:31 PM
> > To: Tomcat Users List
> > Subject: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + 
> separate VMs
> >
> >
> > Larry,
> >
> > The desired target is Tomcat 4.X.  The revision of Apache is
> > of less issue,
> > so for the moment I can install whichever one is best able to
> > provide a
> > working solution.  Right now, we're running Apache 1.3 and
> > JServ with one
> > JVM per virtual host.  Each JVM runs under an appropriate 
> UID for that
> > virtual host.
> >
> > Our specific interest is to upgrade the web application
> > environment while
> > preserving the isolation between virtual hosts.
> >
> > --- Noel
> >
> > -Original Message-
> > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> >
> > It wouldn't hurt to mention which version of Apache and
> > which version of Tomcat.  Regrettably the time I have available
> > to answer questsions (mostly 3.3 and 3.2.x related) is limited.
> > I am usually forced to skip questions that don't bother to
> > mention which verstions are in use.
> >
> > Cheers,
> > Larry
> >
> > > -Original Message-
> > > From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> > >
> > > I am STILL trying to find out how to configure Apache+Tomcat
> > > so that EACH virtual host has ITS OWN JVM.  This seems to be
> > > a fairly common question, but no one seems willing to
> > > actually answer it.
> > >
> > > Ideally we want some means that works well with the perchild
> > > module, so that not only is each virtual host assigned its
> > > own privileges under Apache, but each JVM is also restricted
> > > to the privileges available to that uid.
> > >
> > > Thanks!  :-)
> > >
> > >   --- Noel
> 
> 
> --
> 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]>




AW: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-18 Thread Ralph Einfeldt

As it is possible to use mod_jk in TC 4.* you two could come 
together.

> -Ursprüngliche Nachricht-
> Von: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> Gesendet: Dienstag, 18. Dezember 2001 22:02
> An: Tomcat Users List
> Betreff: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs
> 
> 
> Larry,
> 
> Perhaps if you provide your Tomcat 3.3 solution(s), we could 
> see how they
> might apply to Tomcat 4?
> 
> Whom would know Tomcat 4?
> 
>   --- Noel
> 
> -Original Message-
> From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> 
> Hi Noel,
> 
> Unfortunately my knowledge of Tomcat 4.x internals is still fairly
> limited, so I can't be of much help at this point in time.  My
> primary experience in this area was getting a suitable
> conf/auto/mod_jk generated by Tomcat 3.3 when using virtual hosts.
> 
> Cheers,
> Larry
> 
> > -Original Message-
> > From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, December 18, 2001 3:31 PM
> > To: Tomcat Users List
> > Subject: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + 
> separate VMs
> >
> >
> > Larry,
> >
> > The desired target is Tomcat 4.X.  The revision of Apache is
> > of less issue,
> > so for the moment I can install whichever one is best able to
> > provide a
> > working solution.  Right now, we're running Apache 1.3 and
> > JServ with one
> > JVM per virtual host.  Each JVM runs under an appropriate 
> UID for that
> > virtual host.
> >
> > Our specific interest is to upgrade the web application
> > environment while
> > preserving the isolation between virtual hosts.
> >
> > --- Noel
> >
> > -Original Message-
> > From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> >
> > It wouldn't hurt to mention which version of Apache and
> > which version of Tomcat.  Regrettably the time I have available
> > to answer questsions (mostly 3.3 and 3.2.x related) is limited.
> > I am usually forced to skip questions that don't bother to
> > mention which verstions are in use.
> >
> > Cheers,
> > Larry
> >
> > > -Original Message-
> > > From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> > >
> > > I am STILL trying to find out how to configure Apache+Tomcat
> > > so that EACH virtual host has ITS OWN JVM.  This seems to be
> > > a fairly common question, but no one seems willing to
> > > actually answer it.
> > >
> > > Ideally we want some means that works well with the perchild
> > > module, so that not only is each virtual host assigned its
> > > own privileges under Apache, but each JVM is also restricted
> > > to the privileges available to that uid.
> > >
> > > Thanks!  :-)
> > >
> > >   --- Noel
> 
> 
> --
> 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]>




RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-18 Thread Guido Medina

The normal server.xml contains a directive called host, just copy,paste and
change the name parameter to the host name you want, eliminate all the
context but the empty one (ROOT) and that's it, rename, let the standard for
the standard examples and duplicate it for every host, after activate the
warp connector, go to the Proxy how-to, be patient, is very difficult to
migrate from 3.x to 4.x, but it is not imposible, is not even a big deal,
the key is to read the hold manual, expending two days (6hrs X 2) and that's
it.

Regards,

Guido.

-Original Message-
From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 18, 2001 5:02 PM
To: Tomcat Users List
Subject: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs


Larry,

Perhaps if you provide your Tomcat 3.3 solution(s), we could see how they
might apply to Tomcat 4?

Whom would know Tomcat 4?

--- Noel

-Original Message-
From: Larry Isaacs [mailto:[EMAIL PROTECTED]]

Hi Noel,

Unfortunately my knowledge of Tomcat 4.x internals is still fairly
limited, so I can't be of much help at this point in time.  My
primary experience in this area was getting a suitable
conf/auto/mod_jk generated by Tomcat 3.3 when using virtual hosts.

Cheers,
Larry

> -Original Message-
> From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 18, 2001 3:31 PM
> To: Tomcat Users List
> Subject: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs
>
>
> Larry,
>
> The desired target is Tomcat 4.X.  The revision of Apache is
> of less issue,
> so for the moment I can install whichever one is best able to
> provide a
> working solution.  Right now, we're running Apache 1.3 and
> JServ with one
> JVM per virtual host.  Each JVM runs under an appropriate UID for that
> virtual host.
>
> Our specific interest is to upgrade the web application
> environment while
> preserving the isolation between virtual hosts.
>
>   --- Noel
>
> -Original Message-
> From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
>
> It wouldn't hurt to mention which version of Apache and
> which version of Tomcat.  Regrettably the time I have available
> to answer questsions (mostly 3.3 and 3.2.x related) is limited.
> I am usually forced to skip questions that don't bother to
> mention which verstions are in use.
>
> Cheers,
> Larry
>
> > -Original Message-
> > From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> >
> > I am STILL trying to find out how to configure Apache+Tomcat
> > so that EACH virtual host has ITS OWN JVM.  This seems to be
> > a fairly common question, but no one seems willing to
> > actually answer it.
> >
> > Ideally we want some means that works well with the perchild
> > module, so that not only is each virtual host assigned its
> > own privileges under Apache, but each JVM is also restricted
> > to the privileges available to that uid.
> >
> > Thanks!  :-)
> >
> > --- Noel


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



RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-18 Thread Noel J. Bergman

Larry,

Perhaps if you provide your Tomcat 3.3 solution(s), we could see how they
might apply to Tomcat 4?

Whom would know Tomcat 4?

--- Noel

-Original Message-
From: Larry Isaacs [mailto:[EMAIL PROTECTED]]

Hi Noel,

Unfortunately my knowledge of Tomcat 4.x internals is still fairly
limited, so I can't be of much help at this point in time.  My
primary experience in this area was getting a suitable
conf/auto/mod_jk generated by Tomcat 3.3 when using virtual hosts.

Cheers,
Larry

> -Original Message-
> From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 18, 2001 3:31 PM
> To: Tomcat Users List
> Subject: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs
>
>
> Larry,
>
> The desired target is Tomcat 4.X.  The revision of Apache is
> of less issue,
> so for the moment I can install whichever one is best able to
> provide a
> working solution.  Right now, we're running Apache 1.3 and
> JServ with one
> JVM per virtual host.  Each JVM runs under an appropriate UID for that
> virtual host.
>
> Our specific interest is to upgrade the web application
> environment while
> preserving the isolation between virtual hosts.
>
>   --- Noel
>
> -Original Message-
> From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
>
> It wouldn't hurt to mention which version of Apache and
> which version of Tomcat.  Regrettably the time I have available
> to answer questsions (mostly 3.3 and 3.2.x related) is limited.
> I am usually forced to skip questions that don't bother to
> mention which verstions are in use.
>
> Cheers,
> Larry
>
> > -Original Message-
> > From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> >
> > I am STILL trying to find out how to configure Apache+Tomcat
> > so that EACH virtual host has ITS OWN JVM.  This seems to be
> > a fairly common question, but no one seems willing to
> > actually answer it.
> >
> > Ideally we want some means that works well with the perchild
> > module, so that not only is each virtual host assigned its
> > own privileges under Apache, but each JVM is also restricted
> > to the privileges available to that uid.
> >
> > Thanks!  :-)
> >
> > --- Noel


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




RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-18 Thread Larry Isaacs

Hi Noel,

Unfortunately my knowledge of Tomcat 4.x internals is still fairly
limited, so I can't be of much help at this point in time.  My
primary experience in this area was getting a suitable
conf/auto/mod_jk generated by Tomcat 3.3 when using virtual hosts.

Cheers,
Larry

> -Original Message-
> From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 18, 2001 3:31 PM
> To: Tomcat Users List
> Subject: RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs
> 
> 
> Larry,
> 
> The desired target is Tomcat 4.X.  The revision of Apache is 
> of less issue,
> so for the moment I can install whichever one is best able to 
> provide a
> working solution.  Right now, we're running Apache 1.3 and 
> JServ with one
> JVM per virtual host.  Each JVM runs under an appropriate UID for that
> virtual host.
> 
> Our specific interest is to upgrade the web application 
> environment while
> preserving the isolation between virtual hosts.
> 
>   --- Noel
> 
> -Original Message-
> From: Larry Isaacs [mailto:[EMAIL PROTECTED]]
> 
> It wouldn't hurt to mention which version of Apache and
> which version of Tomcat.  Regrettably the time I have available
> to answer questsions (mostly 3.3 and 3.2.x related) is limited.
> I am usually forced to skip questions that don't bother to
> mention which verstions are in use.
> 
> Cheers,
> Larry
> 
> > -Original Message-
> > From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> >
> > I am STILL trying to find out how to configure Apache+Tomcat
> > so that EACH virtual host has ITS OWN JVM.  This seems to be
> > a fairly common question, but no one seems willing to
> > actually answer it.
> >
> > Ideally we want some means that works well with the perchild
> > module, so that not only is each virtual host assigned its
> > own privileges under Apache, but each JVM is also restricted
> > to the privileges available to that uid.
> >
> > Thanks!  :-)
> >
> > --- Noel
> 
> 
> --
> 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]>




RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-18 Thread Noel J. Bergman

Larry,

The desired target is Tomcat 4.X.  The revision of Apache is of less issue,
so for the moment I can install whichever one is best able to provide a
working solution.  Right now, we're running Apache 1.3 and JServ with one
JVM per virtual host.  Each JVM runs under an appropriate UID for that
virtual host.

Our specific interest is to upgrade the web application environment while
preserving the isolation between virtual hosts.

--- Noel

-Original Message-
From: Larry Isaacs [mailto:[EMAIL PROTECTED]]

It wouldn't hurt to mention which version of Apache and
which version of Tomcat.  Regrettably the time I have available
to answer questsions (mostly 3.3 and 3.2.x related) is limited.
I am usually forced to skip questions that don't bother to
mention which verstions are in use.

Cheers,
Larry

> -Original Message-
> From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
>
> I am STILL trying to find out how to configure Apache+Tomcat
> so that EACH virtual host has ITS OWN JVM.  This seems to be
> a fairly common question, but no one seems willing to
> actually answer it.
>
> Ideally we want some means that works well with the perchild
> module, so that not only is each virtual host assigned its
> own privileges under Apache, but each JVM is also restricted
> to the privileges available to that uid.
>
> Thanks!  :-)
>
>   --- Noel


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-18 Thread Larry Isaacs

It wouldn't hurt to mention which version of Apache and
which version of Tomcat.  Regrettably the time I have available
to answer questsions (mostly 3.3 and 3.2.x related) is limited.
I am usually forced to skip questions that don't bother to
mention which verstions are in use.

Cheers,
Larry

> -Original Message-
> From: Noel J. Bergman [mailto:[EMAIL PROTECTED]]
> Sent: Monday, December 17, 2001 4:18 PM
> To: [EMAIL PROTECTED]
> Subject: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs
> Importance: High
> 
> 
> I am STILL trying to find out how to configure Apache+Tomcat 
> so that EACH
> virtual host has ITS OWN JVM.  This seems to be a fairly 
> common question,
> but no one seems willing to actually answer it.
> 
> Ideally we want some means that works well with the perchild 
> module, so that
> not only is each virtual host assigned its own privileges 
> under Apache, but
> each JVM is also restricted to the privileges available to that uid.
> 
> Thanks!  :-)
> 
>   --- Noel
> 
> 
> --
> 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]>




Re: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-17 Thread James Chuang

Noel:

Let me give this one a shot.  I just did this for Tomcat 3.24 over the
weekend.

To each have a separate JVM, you basically need multiple Tomcat sessions.
Which means, you need multiple server.xml, each with it's own context
definition serving a particular JVM.

So, here is what you need to do:

Configure Apache to support each virtual host.  In my case, I used the
NameVirtualHost settings, and for each virtual host, I had a different
document root.

Create a mod_jk.conf that supports directing traffic to different VHOSTS
based on some sort of path.  This is the important parts:

Alias /host1 "/opt/host1"

Options FollowSymLinks

JkMount /host1/servlet/* ajp13
JkMount /host1/*.jsp ajp13

Alias /host2 "/opt/host2"

Options FollowSymLinks

JkMount /host2/servlet/* ajp13_2
JkMount /host2/*.jsp ajp13_2

Notice that the ajp workers are labeled differently.

Now, modify workers.properties to support the new workers...  There are 2
new workers, one to support the admin functionality of each tomcat server,
and one to support the connection to Apache
>>>
worker.list=ajp12, ajp12_2, ajp13, ajp13_2

worker.ajp12.port=8007
worker.ajp12.host=localhost
worker.ajp12.type=ajp12
worker.ajp12.lbfactor=1
worker.ajp12_2.port=8010
worker.ajp12_2.host=localhost
worker.ajp12_2.type=ajp12
worker.ajp12_2.lbfactor=1

worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13
worker.ajp13.lbfactor=1
worker.ajp13_2.port=8011
worker.ajp13_2.host=localhost
worker.ajp13_2.type=ajp13
worker.ajp13_2.lbfactor=1

Now, make copies of server.xml, one that is server1.xml, and one is
server2.xml.  Server 1 would have context stuff looking like this:







  
  





And server2.xml would have the ports modified appropriately, and with the
right context definition.

Now, start tomcat by doing this:

startup.sh -f  $TOMCAT_HOME/conf/server1.xml

You need to specify the -f parameter for shutdown as well.

If all this is done right, you now have 2 tomcat's running, each with it's
own JVM, each with it's own context and vhost support.

Good luck!

jchuang






- Original Message -
From: "Noel J. Bergman" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, December 17, 2001 1:17 PM
Subject: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs


> I am STILL trying to find out how to configure Apache+Tomcat so that EACH
> virtual host has ITS OWN JVM.  This seems to be a fairly common question,
> but no one seems willing to actually answer it.
>
> Ideally we want some means that works well with the perchild module, so
that
> not only is each virtual host assigned its own privileges under Apache,
but
> each JVM is also restricted to the privileges available to that uid.
>
> Thanks!  :-)
>
> --- Noel
>
>
> --
> To unsubscribe:   <mailto:[EMAIL PROTECTED]>
> For additional commands: <mailto:[EMAIL PROTECTED]>
> Troubles with the list: <mailto:[EMAIL PROTECTED]>
>
>


- Original Message -----
From: "Noel J. Bergman" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, December 17, 2001 1:17 PM
Subject: PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs


> I am STILL trying to find out how to configure Apache+Tomcat so that EACH
> virtual host has ITS OWN JVM.  This seems to be a fairly common question,
> but no one seems willing to actually answer it.
>
> Ideally we want some means that works well with the perchild module, so
that
> not only is each virtual host assigned its own privileges under Apache,
but
> each JVM is also restricted to the privileges available to that uid.
>
> Thanks!  :-)
>
> --- Noel
>
>
> --
> 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]>




PLEASE HELP: Apache+Tomcat - Virtual hosts + separate VMs

2001-12-17 Thread Noel J. Bergman

I am STILL trying to find out how to configure Apache+Tomcat so that EACH
virtual host has ITS OWN JVM.  This seems to be a fairly common question,
but no one seems willing to actually answer it.

Ideally we want some means that works well with the perchild module, so that
not only is each virtual host assigned its own privileges under Apache, but
each JVM is also restricted to the privileges available to that uid.

Thanks!  :-)

--- Noel


--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: apache + tomcat + virtual hosts

2001-07-14 Thread Jeff Kilbride

Hi Connie,

I think the first thing you should do is read the Apache docs on virtual
hosting here:

http://httpd.apache.org/docs/vhosts/index.html

Then go to the archive here:

http://mikal.org/interests/java/tomcat/index.jsp

and do a search on "virtual host jeff" -- this will pull up all my previous
posts on virtual hosting, including examples of my config.

Thanks,
--jeff

- Original Message -
From: "Connie Chan" <[EMAIL PROTECTED]>
To: "Jack Hui" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, July 13, 2001 6:04 AM
Subject: RE: apache + tomcat + virtual hosts


> Jack,
>
> I try a few configuration settings:
>
> Configuration 1:
> I put the default server name in the NameVirtualHost and then create the
> virutal host tag for the virtual host 
>  .  It does not work.  When I browse the default web
> server, the virtual host displays.
>
> Configuration 2:
> I put the default server name in the NameVirtualHost and then create the
> virutal host tag for the default server 
>   and the virtual host 
>  .  It does not work.  When I browse the default web
> server, I get 403 Forbidden error (The error displays You don't have
> permission to access / on this server).
>
> Configuration 3:
> I put '*' in the NameVirtualHost and then create the virutal host tags
> for the default server    and the
> virtual host   .  It does not work.
> Both servers give me 403 Forbidden error.
>
>
> Is the configuration 2 correct?  Should I create another server name as
> the default server name and then have different name for my default web
> server?  Please help.
>
> Thanks,
> Connie
>
>
> -Original Message-
> From: Jack Hui [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, July 12, 2001 9:32 PM
> To: '[EMAIL PROTECTED]'; Connie Chan
> Subject: RE: apache + tomcat + virtual hosts
>
>
> Connie,
>
> Your default server and virtual server are using the SAME IP AND SAME
> PORT
> no., right ?
> What did you put in the NameVirtualHost ? should be the IP of the
> default
> server, right ?
>
> According to the documentation, you have to set the IP to either way (
> not
> 100% sure, but I read before )
>
> But, why don't you put your default sever into the virtual host too ??
> If it
> can be only recognize by the NAME
> the client enter in the browser.
>
> Another solution is you are going to set another IP for all virtual
> host,
> but it involves modifying the DNS entries.
>
> Jack
>
> -Original Message-
> From: Connie Chan [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, July 12, 2001 9:25 PM
> To: [EMAIL PROTECTED]
> Subject: apache + tomcat + virtual hosts
>
>
> Hi,
> Currently, I'm using apache with tomcat.  I have set up the server such
> that it serves a default web server, ssl server (being set up as a
> virtual host with using port 443), and a virtual host (with using port
> 80).  But the document root for default web server and virtual host is
> mixed up. My virtual host and default web server are using the same IP
> address. When I type the default web server, the welcome file for
> virtual host displays. When I type the virtual host, the welcome file
> for the virtual host displays as well. However, if I specify port 8080
> (the HTTP port for tomcat) in the url (for testing tomcat only without
> going thru apache), the default web url would display the correct
> welcome page.
> In my httpd.conf, I have declared
> DocumentRoot d:/jakarta-tomcat/webapps/myapp
> AND
> 
> ServerName vh1.mycomp.com
> DocumentRoot d:/jakarta-tomcat/webapps/vh1
> JkMount /*.jsp ajp12
> JkMount /servlet/* ajp12
> JkMount /email/* ajp12
> 
> AllowOverride None
> deny from all
> 
> 
> AllowOverride None
> deny from all
> 
> 
>
> Do I miss anything?
>
> Thanks,
> Connie
>




RE: apache + tomcat + virtual hosts

2001-07-13 Thread Connie Chan

Jack,

I try a few configuration settings:

Configuration 1:
I put the default server name in the NameVirtualHost and then create the
virutal host tag for the virtual host 
 .  It does not work.  When I browse the default web
server, the virtual host displays.

Configuration 2:
I put the default server name in the NameVirtualHost and then create the
virutal host tag for the default server 
  and the virtual host 
 .  It does not work.  When I browse the default web
server, I get 403 Forbidden error (The error displays You don't have
permission to access / on this server).

Configuration 3:
I put '*' in the NameVirtualHost and then create the virutal host tags
for the default server    and the
virtual host   .  It does not work.
Both servers give me 403 Forbidden error.


Is the configuration 2 correct?  Should I create another server name as
the default server name and then have different name for my default web
server?  Please help.

Thanks,
Connie


-Original Message-
From: Jack Hui [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 12, 2001 9:32 PM
To: '[EMAIL PROTECTED]'; Connie Chan
Subject: RE: apache + tomcat + virtual hosts


Connie,

Your default server and virtual server are using the SAME IP AND SAME
PORT
no., right ?
What did you put in the NameVirtualHost ? should be the IP of the
default
server, right ?

According to the documentation, you have to set the IP to either way (
not
100% sure, but I read before )

But, why don't you put your default sever into the virtual host too ??
If it
can be only recognize by the NAME
the client enter in the browser.

Another solution is you are going to set another IP for all virtual
host,
but it involves modifying the DNS entries.

Jack

-Original Message-
From: Connie Chan [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 12, 2001 9:25 PM
To: [EMAIL PROTECTED]
Subject: apache + tomcat + virtual hosts


Hi,
Currently, I'm using apache with tomcat.  I have set up the server such
that it serves a default web server, ssl server (being set up as a
virtual host with using port 443), and a virtual host (with using port
80).  But the document root for default web server and virtual host is
mixed up. My virtual host and default web server are using the same IP
address. When I type the default web server, the welcome file for
virtual host displays. When I type the virtual host, the welcome file
for the virtual host displays as well. However, if I specify port 8080
(the HTTP port for tomcat) in the url (for testing tomcat only without
going thru apache), the default web url would display the correct
welcome page. 
In my httpd.conf, I have declared 
DocumentRoot d:/jakarta-tomcat/webapps/myapp
AND 
 
ServerName vh1.mycomp.com 
DocumentRoot d:/jakarta-tomcat/webapps/vh1 
JkMount /*.jsp ajp12 
JkMount /servlet/* ajp12 
JkMount /email/* ajp12 
 
AllowOverride None 
deny from all 
 
 
AllowOverride None 
deny from all 
 
 

Do I miss anything? 

Thanks, 
Connie



RE: apache + tomcat + virtual hosts

2001-07-12 Thread Jack Hui

Connie,

Your default server and virtual server are using the SAME IP AND SAME PORT
no., right ?
What did you put in the NameVirtualHost ? should be the IP of the default
server, right ?

According to the documentation, you have to set the IP to either way ( not
100% sure, but I read before )

But, why don't you put your default sever into the virtual host too ?? If it
can be only recognize by the NAME
the client enter in the browser.

Another solution is you are going to set another IP for all virtual host,
but it involves modifying the DNS entries.

Jack

-Original Message-
From: Connie Chan [mailto:[EMAIL PROTECTED]]
Sent: Thursday, July 12, 2001 9:25 PM
To: [EMAIL PROTECTED]
Subject: apache + tomcat + virtual hosts


Hi,
Currently, I'm using apache with tomcat.  I have set up the server such
that it serves a default web server, ssl server (being set up as a
virtual host with using port 443), and a virtual host (with using port
80).  But the document root for default web server and virtual host is
mixed up. My virtual host and default web server are using the same IP
address. When I type the default web server, the welcome file for
virtual host displays. When I type the virtual host, the welcome file
for the virtual host displays as well. However, if I specify port 8080
(the HTTP port for tomcat) in the url (for testing tomcat only without
going thru apache), the default web url would display the correct
welcome page. 
In my httpd.conf, I have declared 
DocumentRoot d:/jakarta-tomcat/webapps/myapp
AND 
 
ServerName vh1.mycomp.com 
DocumentRoot d:/jakarta-tomcat/webapps/vh1 
JkMount /*.jsp ajp12 
JkMount /servlet/* ajp12 
JkMount /email/* ajp12 
 
AllowOverride None 
deny from all 
 
 
AllowOverride None 
deny from all 
 
 

Do I miss anything? 

Thanks, 
Connie



apache + tomcat + virtual hosts

2001-07-12 Thread Connie Chan

Hi,
Currently, I'm using apache with tomcat.  I have set up the server such
that it serves a default web server, ssl server (being set up as a
virtual host with using port 443), and a virtual host (with using port
80).  But the document root for default web server and virtual host is
mixed up. My virtual host and default web server are using the same IP
address. When I type the default web server, the welcome file for
virtual host displays. When I type the virtual host, the welcome file
for the virtual host displays as well. However, if I specify port 8080
(the HTTP port for tomcat) in the url (for testing tomcat only without
going thru apache), the default web url would display the correct
welcome page. 
In my httpd.conf, I have declared 
DocumentRoot d:/jakarta-tomcat/webapps/myapp
AND 
 
ServerName vh1.mycomp.com 
DocumentRoot d:/jakarta-tomcat/webapps/vh1 
JkMount /*.jsp ajp12 
JkMount /servlet/* ajp12 
JkMount /email/* ajp12 
 
AllowOverride None 
deny from all 
 
 
AllowOverride None 
deny from all 
 
 

Do I miss anything? 

Thanks, 
Connie




Re: Apache + Tomcat + virtual hosts - worker not found

2000-11-21 Thread Dominique BATARD

I've got the same problem with my mandrake 7.2 box

Recompile mod_jk from sources

Dom

- Original Message - 
From: "Norton Lam" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, November 21, 2000 10:27 AM
Subject: Apache + Tomcat + virtual hosts - worker not found


> Hi,
> 
> I'm having a strange problem and can't seem to find any solution in
> the FAQ or this mailing list archive.
> 
> I'm running RedHat 6.2, Apache 1.3.14, and Tomcat 3.1.  I installed
> mod_jk in Apache and appear to have all the server.xml and
> workers.properties files set up correctly.  Both Apache and Tomcat
> work individually, but not together.
> 
> I'm able to hit pages on intranet.domain.com (apache) and
> intranet.domain.com:8087 (tomcat) and get servlets and JSPs
> to work on the tomcat server.  But I get a 500 error returned from
> the apache server when I try to access a JSP page.
> 
> In the jk.log, I get the following error:
> 
> [jk_uri_worker_map.c (255)]: Into
> jk_uri_worker_map_t::uri_worker_map_open, suffix rule /.jsp=intranet was
> added
> [jk_uri_worker_map.c (266)]: Into
> jk_uri_worker_map_t::uri_worker_map_open, match rule /servlet/=intranet
> was added
> [jk_uri_worker_map.c (295)]: Into
> jk_uri_worker_map_t::uri_worker_map_open, there are 2 rules
> [jk_uri_worker_map.c (316)]: jk_uri_worker_map_t::uri_worker_map_open,
> done
> [jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
> [jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker,
> done without a match
> [jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
> [jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker,
> done without a match
> [jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
> [jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker,
> done without a match
> [jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
> [jk_uri_worker_map.c (406)]: jk_uri_worker_map_t::map_uri_to_worker,
> Found a match intranet
> [jk_worker.c (123)]: Into wc_get_worker_for_name intranet
> [jk_worker.c (127)]: wc_get_worker_for_name, done did not found a worker
> 
> 
> Note at the top of ths snippet, the rules were added ok.
> 
> Here are snippets of my config files:
> 
> httpd.conf:
> 
> 
> DocumentRoot /home/www/intranet/htdocs
> ServerName intranet.domain.com
> ErrorLog /home/www/intranet/logs/error_log
> CustomLog /home/www/intranet/logs/access_log common
> 
> JkWorkersFile /usr/local/tomcat/conf/workers-intranet.properties
> JkLogFile  /home/www/intranet/logs/jk.log
> JkLogLevel warn
> JkMount /*.jsp intranet
> JkMount /servlet/* intranet
> 
> 
> 
> workers-intranet.properties:
> 
> #
> # workers.tomcat_home should point to the location where you
> # installed tomcat. This is where you have your conf, webapps and lib
> # directories.
> #
> workers.tomcat_home=/usr/local/tomcat
> 
> #
> # workers.java_home should point to your Java installation. Normally
> # you should have a bin and lib directories beneath it.
> #
> workers.java_home=/usr/local/java
> 
> #
> # You should configure your environment slash... ps=\ on NT and / on
> UNIX
> # and maybe something different elsewhere.
> #
> # ps=\
> ps=/
> 
> #
> #-- ADVANCED MODE 
> #-
> #
> 
> #
> #-- DEFAULT worker list --
> #-
> #
> #
> # The workers that your plugins should create and work with
> #
> worker.list=intranet
> 
> #
> #-- DEFAULT ajp12 WORKER DEFINITION --
> #-
> #
> 
> #
> # Defining a worker named www and of type ajp12
> # Note that the name and the type do not have to match.
> #
> worker.intranet.port=8007
> worker.intranet.host=localhost
> worker.intranet.type=ajp12
> #
> # Specifies the load balance factor when used with
> # a load balancing worker.
> # Note:
> #  > lbfactor must be > 0
> #  > Low lbfactor means less work done by the worker.
> # worker.intranet.lbfactor=1
> 
> server-intranet.xml:
> 
>  className="org.apache.tomcat.service.SimpleTcpConnector">
>  value="org.apache.tomcat.service.http.Http
> ConnectionHandler"/>
> 
> 
> 
>  className="org.apache.tomcat.service.SimpleTcpConnector">
>  value="org.apache.tomcat.service.connector
> .Ajp12ConnectionHandler"/>
> 
> 
> 
> 
> I first start tomcat with 'tomcat.sh start -f
> /usr/local/tomcat/conf/server-intranet-xml', then start apache.
> 
> Everything looks hunky doory, but the connection between the two
> isn't happening.
> 
> Any help anyone can give me would be greatly appreciated.
> 
> TIA
> 
> Norton




Apache + Tomcat + virtual hosts - worker not found

2000-11-21 Thread Norton Lam

Hi,

I'm having a strange problem and can't seem to find any solution in
the FAQ or this mailing list archive.

I'm running RedHat 6.2, Apache 1.3.14, and Tomcat 3.1.  I installed
mod_jk in Apache and appear to have all the server.xml and
workers.properties files set up correctly.  Both Apache and Tomcat
work individually, but not together.

I'm able to hit pages on intranet.domain.com (apache) and
intranet.domain.com:8087 (tomcat) and get servlets and JSPs
to work on the tomcat server.  But I get a 500 error returned from
the apache server when I try to access a JSP page.

In the jk.log, I get the following error:

[jk_uri_worker_map.c (255)]: Into
jk_uri_worker_map_t::uri_worker_map_open, suffix rule /.jsp=intranet was
added
[jk_uri_worker_map.c (266)]: Into
jk_uri_worker_map_t::uri_worker_map_open, match rule /servlet/=intranet
was added
[jk_uri_worker_map.c (295)]: Into
jk_uri_worker_map_t::uri_worker_map_open, there are 2 rules
[jk_uri_worker_map.c (316)]: jk_uri_worker_map_t::uri_worker_map_open,
done
[jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker,
done without a match
[jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker,
done without a match
[jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (434)]: jk_uri_worker_map_t::map_uri_to_worker,
done without a match
[jk_uri_worker_map.c (344)]: Into jk_uri_worker_map_t::map_uri_to_worker
[jk_uri_worker_map.c (406)]: jk_uri_worker_map_t::map_uri_to_worker,
Found a match intranet
[jk_worker.c (123)]: Into wc_get_worker_for_name intranet
[jk_worker.c (127)]: wc_get_worker_for_name, done did not found a worker


Note at the top of ths snippet, the rules were added ok.

Here are snippets of my config files:

httpd.conf:


DocumentRoot /home/www/intranet/htdocs
ServerName intranet.domain.com
ErrorLog /home/www/intranet/logs/error_log
CustomLog /home/www/intranet/logs/access_log common

JkWorkersFile /usr/local/tomcat/conf/workers-intranet.properties
JkLogFile  /home/www/intranet/logs/jk.log
JkLogLevel warn
JkMount /*.jsp intranet
JkMount /servlet/* intranet



workers-intranet.properties:

#
# workers.tomcat_home should point to the location where you
# installed tomcat. This is where you have your conf, webapps and lib
# directories.
#
workers.tomcat_home=/usr/local/tomcat

#
# workers.java_home should point to your Java installation. Normally
# you should have a bin and lib directories beneath it.
#
workers.java_home=/usr/local/java

#
# You should configure your environment slash... ps=\ on NT and / on
UNIX
# and maybe something different elsewhere.
#
# ps=\
ps=/

#
#-- ADVANCED MODE 
#-
#

#
#-- DEFAULT worker list --
#-
#
#
# The workers that your plugins should create and work with
#
worker.list=intranet

#
#-- DEFAULT ajp12 WORKER DEFINITION --
#-
#

#
# Defining a worker named www and of type ajp12
# Note that the name and the type do not have to match.
#
worker.intranet.port=8007
worker.intranet.host=localhost
worker.intranet.type=ajp12
#
# Specifies the load balance factor when used with
# a load balancing worker.
# Note:
#  > lbfactor must be > 0
#  > Low lbfactor means less work done by the worker.
# worker.intranet.lbfactor=1

server-intranet.xml:












I first start tomcat with 'tomcat.sh start -f
/usr/local/tomcat/conf/server-intranet-xml', then start apache.

Everything looks hunky doory, but the connection between the two
isn't happening.

Any help anyone can give me would be greatly appreciated.

TIA

Norton

begin:vcard 
n:Lam;Norton
tel;pager:[EMAIL PROTECTED]
tel;cell:651.283.6823
tel;work:651.283.6823
x-mozilla-html:TRUE
url:http://www.lamconsulting.com/
org:Lam Consulting, LLC
adr:;;
version:2.1
email;internet:[EMAIL PROTECTED]
title:President
x-mozilla-cpt:;-24784
fn:Norton Lam
end:vcard