title: Tomcat shutdown VERY slow after calling shutdown.sh?
body: <p>My situation is like this:</p>
  
  <p>Everytime before uploading war file to web-app folder, I stop Tomcat by calling <code>sh shutdown.sh</code>. It used to take about 30 seconds for a total shutdown. But now it doesn't work well anymore.</p>
  
  <p>Actually, it did some work, because when I access the application from web-page it throws 503 error (Under Maintenance). But when I use <code>ps aux | grep tomcat</code> to check, the tomcat process is still there. And it will be there for around 5 - 10 mins.</p>
  
  <p>I understand that it may need to take extra times to complete all the tasks, but it is way too slow (5 - 10 minutes), before it is stop totally. I don't understand why this happens, but there must be some reason. Maybe there's something to do with the code, or the new script of deployment we used recently. I just have almost no clue about where to check.</p>
  
  <p>This is important to our team because we are using "auto-deployment", in which we use a script to auto-package war file, uploading and deploy on a specific time. If we started a new tomcat instance before the old one successfully shutdown, it will hang there for eternal, and cleaning up task by "kill -9" is daunting.</p>
  
  <p>Is there anyone who has experimented this issue? Any clue would be appreciated.</p>