How to remove undeploy / completley-remove.war deployed in the webapps directory when Tomcat 6.x is removed?

Does anyone know of a method to delete all webapps deployed from .war files when deleting Tomcat (others, then Shift + Delete ...)? The reason I'm asking for is described below.

I use InstallShield 2009 to host a copy of the JRE and Tomcat 6.x, where starting / stopping Tomcat uses org.apache.catalina.startup.Bootstrap and is registered as a Windows service with a user name. When the "program" is deleted, some directories should be left behind, for example, log files.

There is also behavior in place where Installshield does not delete directories or files that it did not install. For example, InstallShield has a link to <filename>.war , but not extended content in <filename>/<files> and <filename>/<directories> when Tomcat is installed and the WAR file is extracted.

+4
source share
5 answers

The method for completely deleting Tomcat and .WAR files used to satisfy InstallShield2009 was (via InstallShield2009):

  • Delete the .WAR file
  • Restart Tomcat Service
  • Expanded exploded directories from a .WAR file have already been deleted or are now deleted.
  • Stop the Tomcat service.
  • Uninstall Tomcat.

If anyone knows a way using the command line or tell Tomcat something to delete all or specific directories in / webapps /, then answer, otherwise I'm going to take the above steps as an answer.

+3
source

Stop tomcat, delete .war files, start tomcat and the exploded folders will be deleted.

+9
source

If you want to delete it when uninstalling Tomcat, then the .war files in the webapps directory and the work files located in the work directory will also be deleted. Therefore, I really do not understand. And if removal means something else, you now know where to look and what to do :)

+2
source

if you want to avoid all this hacked military hack file, try modifying the Tomcat Server.xml file.

 <Host name="localhost" appBase="webapps" unpackWARs="true" autoDeploy="true"> 

in

 <Host name="localhost" appBase="webapps" unpackWARs="false" autoDeploy="true"> 
+2
source

Go to the tomcat homepage. Click "Application Manager." Please enter a valid username and password. You will see a list of all applications. Find your app. The "undeploy" button appears. Click on it. Done!

+2
source

All Articles