I have used, after a little struggle, an internet-application on the (remote) Tomcat 5.5 server (Turnkey Linux includes that). It's a GoogleWebToolkit web-application having a Java after sales.
Watching the logs everything went fine. The /manager application also shows 'running=true' on my small new application.
The main problem is, visiting the /myApp url gives 404. What I have done to date, to no success:
- Ensured it will run in your area using Eclipse, works fine there
- Checked the logs around the deployment server, it succesfully loads Spring, plus some other libraries. Actually, it shows exactly the same messages as after i run it in located-mode in Eclipse
- The /manager, /host-manager, /admin programs run fine.
- Reloading the application on /manager also states 'OK'
- I've got a welcome file specified, one that's really there, directly striking which gives 404
- I personally use the default host ('localhost'), similar to the /manager, /host-manager and /admin applications
- Did lots of doing a search online, with no success.
- Attempted another Tomcat (v6) server (home ubuntu box, the main one I wish to deploy on is really a VPS somewhere around the internet), there it simply works... Re-install the VPS?
Any hints regarding how to fix this, discover what the issue is, or what could potentially cause this? Will there be conflicts? there's another application running within the $CATALINA_HOME/webapps dir, can that conflict with myApp, which is incorporated in the same directory used?
Below is my server.xml
<?xml version="1.0" encoding="UTF-8"?> <Server> <Listener className="org.apache.catalina.core.AprLifecycleListener"/> <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"/> <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener"/> <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener"/> <GlobalNamingResources> <Environment name="simpleValue" type="java.lang.Integer" value="30"/> <Resource auth="Container" description="User database that can be updated and saved" name="UserDatabase" type="org.apache.catalina.UserDatabase" pathname="conf/tomcat-users.xml" factory="org.apache.catalina.users.MemoryUserDatabaseFactory"/> </GlobalNamingResources> <Service name="Catalina"> <Connector port="8009" redirectPort="8443" address="127.0.0.1" protocol="AJP/1.3"> </Connector> <Engine defaultHost="localhost" name="Catalina"> <Realm className="org.apache.catalina.realm.UserDatabaseRealm"/> <Host appBase="webapps" name="localhost"> </Host> </Engine> </Service> </Server>
So you've an Apache instance relaxing in front of Tomcat. Some/all demands to Apache are submitted to Tomcat AJP port 8009. Presuming this Apache-Tomcat bridge is working ok, and therefore focusing only in your used application, you most likely have to then add
JKMount directives into Apache's
httpd.conf file, to make sure that demands to
/myApp url truly are submitted to Tomcat. Otherwise, they're offered by Apache, meaning you receive a 404 error when individuals assets aren't found.