title: debugging tomcat crash
body: <p>I have an instance of Tomcat which periodically crashes for unknown reasons.</p>
  
  <p>There are no errors left in the logs, only a line in Event Viewer saying "Tomcat terminated unexpectedly".</p>
  
  <p>In a test environment I have been unable to replicate the issue. I am therefore mostly restricted to passive monitoring of the production environment.</p>
  
  <p>The problem does not seem to be related to memory as the unexpected terminations show no obvious correlation to the process' memory usage.</p>
  
  <p>What steps could I take to further diagnose this problem?</p>
  
  <p>EDIT:</p>
  
  <p>Some corrections/clarifications:</p>
  
  <p>It is actually not a single "instance" of Tomcat, rather several instances with similar configurations.</p>
  
  <p>OS is Windows 2003.</p>
  
  <p>Java version is Java 6.</p>
  
  <p><strong>UPDATE:</strong></p>
  
  <p>Looks like the issue might be related to memory after all. Discovered some crash dumps which were created in the Tomcat directory (not .../Tomcat/logs).</p>
  
  <p>The dumps mostly contained errors such as:</p>
  
  <p>java.lang.OutOfMemoryError: requested 32756 bytes for ChunkPool::allocate. Out of swap space?</p>
  
  <p>This is unexpected as the process sometimes crashed when it's memory usage was a relatively low point (compared to historical usage).</p>
  
  <p>In all dumps, perm gen space is at 99% usage, but in absolute terms this usage is not consistent, and is nowhere near the limit specified in -XX:MaxPermSize.</p>