Alistair's picture

I am trying to deploy the xmondrian webapp to a virtual machine running Tomcat on Apache.

more on xmondrian here -

I have used the webapp manager page to select and deploy the xmondrain.war file.

I get an 'OK' message at the top and xmondrian appears in the list of applications.

But when I click on the link, or attempt to access it at 192.168.1.xx/xmondrian i get the following message

'Not Found

The requested URL was not found on this server.'

Can anyone advise what I am doing wrong?

Jeremy Davis's picture

First up, I'm not super experienced with Tomcat in general, even less so with the intricacies that may well apply to the Tomcat on Apache server. Regardless, I do have an intimate knowledge of the TurnKey library and know where to find all the build code etc, so hopefully I'll still be able to help out.

First up, unless you plan to also provide plain html pages (and/or host other content separate to Tomcat) then you may actually be better off with just the vanilla Tomcat appliance?!

If you're sure that you want the Tomcat on Apache appliance, then the next thing to consider is that in this specific appliance (unlike the vanilla Tomcat server) Tomcat is provided via a reverse proxy. As noted (hinted?) on the appliance page, the default (TurnKey) landing page (AKA "web control panel") is a (mini) java app installed to /var/lib/tomcat8/webapps/cp. The default Apache index page (/var/www/index.html) provides a javascript redirect to show the landing page.

I'm not 100% sure exactly how all the routing works, but I'm guessing that perhaps the Apache routing overrides the Tomcat routing? As a troubleshooting step, perhaps try changing the default Apache index page to instead redirect to where your app should be?! (Although I note that actually, in this scenario, you'd be redirecting to YOUR_SERVER/xmondrian - which you already noted doesn't work...).

So for further troubleshooting steps, you may wish to double check the Apache log. Perhaps there might be some hints there? You should find that at /var/log/apache2/error.log.

Actually, I just had a quick browse through the build code and I just noticed that the Tomcat urls being served by Apache appear to be configured in the mod_jk config file. Have a look here: /etc/tomcat8/mod_jk.conf Perhaps if you also added your app there it might "just work"!? Please note that a restart of Apache and/or Tomcat will likely be required to apply your changes. FYI, something like this:

systemctl restart apache2
systemctl restart tomcat

Hopefully that's of some value and gets you headed in the right direction. Either way, please post back and tell us how you go. If you still need more help, please share any extra info you come across and I'll dig in a bit deeper and test it out myself.

Add new comment