Reputation: 12123
I have access to a Tomcat server that is currently deploy two webapps. When I put my own webapp in the apache-tomcat-6.xxx/webapps directory, it doesn't deploy it. I tried downloading the Tomcat sample webapp, and deployed it in the webapps directory, and it still doesn't deploy.
Is there anything I have to do beyond putting the webapps in the apache*/webapps directory to get them to deploy? I have tried starting/restarting Tomcat ad nauseam.
Thanks,
ktm
Upvotes: 4
Views: 14607
Reputation: 18923
The problem that I faced was there were too many java processes that were running. Somehow it was not letting Tomcat start and did not throw any error.
For that I killed all the java processes and then restarted the Tomcat and it worked.
In Linux:
> ps -aux | grep java
> kill -9 [pid_from_last_command]
Upvotes: 0
Reputation: 1
i also meet the problem,i redownload tomcat and check service.xml carefully,finnally i find my WEB-INF/web.xml not exsit.
Upvotes: 0
Reputation: 11
I had a problem with tomcat 6's deployment system. For some reason the file $CATALINA_HOME/conf/Catalina/localhost/MyAppName.xml was zero-length... I'm not sure about what caused it, but I deleted the zero-lenght XML, deleted the WAR and then I repeated the deployment process (copied the WAR to the webapps directory) and it deployed correctly. I found the failure message in a log file... now I know it for the next time, but I though it would be worth to share just in case...
Hope it helps...
Upvotes: 0
Reputation: 2140
Ensure that permissions on your war file belongs to the tomcat user and group. Make sure to remove the deployed directory first, and then restart the server.
$ sudo rm -fr /path/to/tomcat/webapps/<yourwebapp>
$ sudo chown tomcat:tomcat /path/to/tomcat/webapps/<yourwebapp.war>
Now restart the server
Upvotes: 0
Reputation: 23186
If you export your .war file from eclipse, make sure your project's dynamic web module facet version is not more than what your production server can handle. For example, version 3.0 works for Tomcat 7, but doesn't work on Tomcat 6, which needs it to be set as 2.5. To knock the project facet version down a notch, see this question.
Upvotes: 0
Reputation: 24316
Check to see if the security manager is running. If it is you will need to edit the catalina.policy file to allow your web application to be deployed and accessed.
Upvotes: 0
Reputation: 2753
Is your server getting started? And if yes than your project directory is created in webapps. Also look for environment variable.
Upvotes: 0
Reputation: 40160
When you say you put your own webapp, I assume you are putting your webapp.war
file? Make sure you delete the existing webapp
directory first before you place webapp.war
. Tomcat will automatically inflate the war file to create that webapp
directory.
Upvotes: 1