J
Jan Burse
Arne said:daemon => run in background, you stop and start via the scripts
in init.d (or use one the GUI tools on top of that)
console app => run in xterm, you start by running sh file and
stop with CTRL/C
Arne
I guess CTRL/C will kill the tomcat app.
When running as console app, you can open a second xterm, and
run the stop sh file. This will inform the currently running
tomcat and initiate a proper shutdown sequence.
Instead of keeping the first xterm open, you can also executed
the start sh file instead of the run sh file. But keeping the
first xterm open is sometimes useful, since you can directly
observe in the console what tomcat is doing via what it writes
on stdout/stderr.
But stdout/stderr are also available as log files. So nothing
gets lost when you don't keep the first xterm open.
Web contexts might install some listeners, which will get
informed during shutdown of tomcat, and can do some additional
work during shutdown:
<web-app>
<!-- Usual stuff here -->
<listener>
<listener-class>com.mycompany.MyClass</listener-class>
</listener>
</web-app>
When using the Tomcat Monitor control on Windows, it will also
shutdown a tomcat app this way, and not simply kill it.
I am not sure whether some newer Tomcat version do also memory
leak detection during shut down, at least it seems to me that
this is done when contexts are reloaded.
Be