tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: Mod_jk Configuration
Date Sun, 25 Jan 2015 22:18:53 GMT
Hash: SHA256


On 1/23/15 7:49 PM, Chris Arnold wrote:
>> *sigh*
>> If you only want to proxy for one VirtualHost, then only set up 
>> JkMounts in that one VirtualHost.
>> Like this:
>> <VirtualHost *:80> ServerName
>> JkMount /* worker1 (or "balancer", whichever you want) 
>> </VirtualHost>
> Maybe I wasn't clear in my other reply, the above jkmount /*
> worker1 sends all requests to the tomcat app. So a request to
> http://domain.tld would get you to the tomcat app (not what we
> want)

Then your virtual hosts are not set up correctly. If you have a
VirtualHost for and a separate VirtualHost for
then the settings should not bleed across.

>> If you want to map / to /share it's a giant pain in the neck and
>> I don't think you will actually be able to accomplish. Best to
>> proxy /share to /share, or, better yet, re-name your application
>> to ROOT.war and proxy "/" to "/".
> Renaming the war would, I believe, will break everything.


>> You should not have needed to change
> Maybe not but u doing so, I have eliminated all the extra clutter
> in as being the problem
>>> and the vhost:
>>> JkMount /share2/* worker1 but this gives a 404 *sigh*:
>> For what URL?
> If I understand your question, https://share2.domain.tld. I found 
> that the /share2/* part of jkmount /share2/* worker1 should be
> just /share/*. Changed to just /share/* and now
> https://share2.domain.tld takes you to the root (/srv/www/hotdogs)
> and that is not even where our sites are hosted
> (/srv/www/htdocs/sites).

Then your DocumentRoot is not set correctly. I highly recommend that
you have an expert take a look at your httpd configuration... it
sounds severely mis-configured.

> However, if I put a port 80 redirect to port 443 in the vhost and
> go to http://share2.domain.tld, that gets me to the correct tomcat
> app (https://share2.domain.tld/share)
>> Don't mess with the Tomcat configuration. Basically, stop
>> touching things.
> My replies have not alluded to any messing with tomcat config.
>> What URL can you use to get to the application *without* httpd in
>> the middle?
> https://share2.domain.tld:8443/share
> You can see why we need users to be able to type share2.domain.tld 
> and arrive at the tomcat app. If you contact me off list I will be 
> happy to give you the complete url so you can see exactly the
> address that is need to get to. I don't want that info on a
> publicly index mailing list.

If you won't re-name the web application, I think redirects will be
your best bet. If a client requests http(s)://share2.domain.tld/, you
should redirect them to https://share2.domain.tld/share/ and then
"JkMount /share/* worker1". You can redirect using RedirectPermanant
or a few other things like having an index.html with an HTTP-EQUIV
header in it.

At this point, you seem to be able to successfully connect httpd ->
Tomcat. If you don't want to follow our advice for a more robust
configuration, you don't have to.

- -chris
Version: GnuPG v1
Comment: GPGTools -


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

View raw message