卸载Tomcat 6.x时,如何取消部署/完全删除部署在webapps目录下的.war?
有谁知道卸载 Tomcat 时删除从 .war 文件部署的所有 Web 应用程序的方法(除了 Shift + Delete ......)?我问的原因如下所述。
我正在使用 InstallShield 2009 放置 JRE 和 Tomcat 6.x 的副本,其中 Tomcat 启动/停止使用 org.apache.catalina.startup.Bootstrap 并注册为 Windows 服务自定义名称。卸载“程序”时,需要保留某些目录,例如日志文件。
还有一种行为,Installshield 不会删除未安装的目录或文件。例如,InstallShield 引用了
,但没有将内容扩展为
和
当安装 Tomcat 并提取 WAR 文件时。
Does anyone know of a method to remove all webapps deployed from .war files when uninstalling Tomcat (other then Shift + Delete . . .)? The reason I ask is is described below.
I am using InstallShield 2009 to lay down a copy of the JRE and Tomcat 6.x, where the Tomcat start/stop uses org.apache.catalina.startup.Bootstrap
and is registered as a Windows service with a custom name. When the "program" is uninstalled certain directories need to be left behind, such as log files.
There is also behavior in place, where Installshield does not remove directories or files that it did not install. For example InstallShield has a reference to <filename>.war
, but not the expanded contents into <filename>/<files>
and <filename>/<directories>
when Tomcat is installed and the WAR file is extracted.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
停止tomcat,删除.war文件,启动tomcat,分解的文件夹被删除。
Stop tomcat, delete the .war files, start tomcat, and the exploded folders are deleted.
用于满足 InstallShield2009 要求的完全删除 Tomcat 和 .WAR 文件的方法是(通过 InstallShield2009):
如果有人知道通过命令行开关或其他方式告诉 Tomcat 删除 /webapps/ 下的所有或特定目录的方法,请回复,否则我将接受上述步骤作为答案。
The method of complete removal of Tomcat and .WAR files used to satisfy InstallShield2009 was to (via InstallShield2009):
If anyone out there knows of a way via command-line switch or something to tell Tomcat to remove all, or specific directories under /webapps/ then please respond, otherwise I'm going to accept the steps above as the answer.
进入tomcat主页。
单击管理器应用程序。提供正确的用户名和密码。
您将看到所有应用程序的列表。
找到您的应用程序。
有一个“取消部署”按钮。
单击它。
完毕!
Go to tomcat homepage.
Click on Manager App. Give proper username and password.
You will see a list of all applications.
Locate your app.
There is a button "undeploy".
Click it.
Done!
如果您想避免整个战争文件爆炸的麻烦,请尝试更改
location-of-tomcat\conf\server.xml
文件。进入
if you want to avoid the this whole exploded war file hassle try to alter
location-of-tomcat\conf\server.xml
file.into
如果卸载Tomcat意味着删除它,那么
webapps
目录下的.war文件和位于work
目录下的工作文件也将被删除。所以我其实不太明白这个问题。如果卸载意味着其他事情,您现在知道在哪里查找以及做什么:)If by uninstalling Tomcat you mean deleting it, then the .war files under the
webapps
directory and the working files located in thework
directory will be deleted too. So I actually don't really get the question. And if uninstalling means something else, you now know where to look and what to do :)