tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From André Warnier>
Subject Re: http and/or ajp connectors
Date Wed, 18 Nov 2009 22:14:06 GMT
Jeffrey Trimble wrote:
> To answer a few questions:
> I'm running apache and tomcat on the same server (AIX).  I'm also 
> running VIPA (Virtual IP Addresses)
> under AIX.  So, I have apache serving up one IP address (Vhost) without 
> the need for tomcat on
> port 80.  It serves up some documentation for users.
> The second IP/Vhost is running DSpace software.  DSpace runs off Tomcat, 
> but there are several
> webapps that can run under the DSpace/Tomcat servlets.  Here's the rundown:
>     (JSP front end)
>    (Running xmlui interface/cocoon)
>       (Harvester)
>    (Another interface for 
> specific uploads--we aren't using currently)
> As you can see I'd like to do TWO things here:
> 1.    Remove the port issue if possible--makes it simpler on users and 
> shorter too.
> 2.    Redirect to 
> interface and keep the other interfaces.
> Does this help analyze the situation?  Currently, I've just kept a 
> simple redirect for
> to the first example in the list.
Going back then to your original post :
 > redirect "/" "http"//"
That one, you drop, because it is the one that caused your original 
endless loop.

 > Then I had a ProxyPass in the httpd.conf file:
 > ProxyPass /jspui
 > ProxyPassReverse /jspui

Old African proverb : to eat an elephant, one has to do it a little bit 
at a time.

So first issue # 1 :

Just do this in Apache httpd :
 > ProxyPass /jspui
 > ProxyPassReverse /jspui

and do similar things for your other webapps, like
 > ProxyPass /xmlui

(In other words, whatever comes in into Apache on port 80, you proxy to 
Tomcat on its currently configured port 8080.  To the user, it appears 
that everything is answered by Apache httpd, thus on the default port 
80, which being the default, does not need to be specified in the URL)

Once that is working, to tackle issue # 2, the fact that you would 
apparently like to have it so that if a user requests :
they would in fact be directed to Tomcat's "/jspui" webapp, you can use 
either one of two methods :

1a) make "/jspui" become your "default" Tomcat application.
For that, you have to rename it to ROOT.  There are plenty of 
explanations available about this in previous threads on this list, or 
else there is a superb tutorial about it in the FAQ.
(  , see #38)
The end result will be that, for Tomcat, your former "/jspui" 
application will now respond to the URL
1b) of course you then need to change your ProxyPass directive, so that 
Apache would proxy to Tomcat's new default application, the URL  (in other words, "/")
That is left as an exercise to the reader.
(But, if you do a ProxyPass of "/", make sure you put that one as the 
last ProxyPass, to give the others a chance).


2) use mod_rewrite under Apache, to rewrite the URL (in other words, "/")
and then just proxy this to Tomcat like above.

This is all assuming that in your Apache VirtualHost for 
"", you just proxy everything to Tomcat, and do not 
want, with this VirtualHost, to serve anything directly from Apache.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message