为什么我们需要为tomcat运行shutdown.bat
我通过运行startup.bat来启动tomcat,并且将会有一个小的cmd窗口运行tomcat。 之后我想停止tomcat并关闭该窗口。
顶猫停了下来。 那么 shutdown.bat 有什么意义呢?
i start tomcat by running startup.bat and there will be a small cmd-window running the tomcat.
After that i wanted to stop tomcat and I close that window.
And topcat stopped.
so what is the point of shutdown.bat?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
shutdown.bat 允许 Tomcat 在需要时自行清理。通过命令关闭而不仅仅是关闭窗口的功能还允许远程管理。
shutdown.bat
allows Tomcat to clean up after itself, if it needs to. The functionality to shutdown from a command instead of just closing a window also allows for remote management.大多数应用程序可以通过多种方式关闭;有一种“优雅”的方式,程序可以自行清理;不太优雅的方式,程序可以尝试捕获关闭(终止)信号;还有一种严酷的方式,即程序被“杀死”(unix 中的kill -9)。关闭窗口可能更接近第二种方式。
当然,如果您无法访问远程服务器上的窗口环境,它就无法正常工作。
Most applications can be shutdown in more than one way; there's the "graceful" way, where a program can clean up after itself; the less-than graceful way, where a program can try to catch a shutdown (termination) signal; and the harsh way, where a program is "killed" (kill -9 in unix). Closing the window is probably closer to the second way.
And of course it wouldn't work very well if you didn't have access to a windowing environment on a remote server.