Home  >  Q&A  >  body text

java - ssh整合问题,,tomcat6,运行时一开始没错,过一段时间就会报下面这个错,但是还是能运行?

Illegal access: this web application instance has been stopped already. Could not load com.mchange.v2.resourcepool.BasicResourcePool$1DestroyResourceTask. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.java.lang.IllegalStateException

at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1566)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526)
at com.mchange.v2.resourcepool.BasicResourcePool.destroyResource(BasicResourcePool.java:980)
at com.mchange.v2.resourcepool.BasicResourcePool.removeResource(BasicResourcePool.java:1406)
at com.mchange.v2.resourcepool.BasicResourcePool.removeResource(BasicResourcePool.java:1378)
at com.mchange.v2.resourcepool.BasicResourcePool.cullExpired(BasicResourcePool.java:1462)
at com.mchange.v2.resourcepool.BasicResourcePool.access$1900(BasicResourcePool.java:32)
at com.mchange.v2.resourcepool.BasicResourcePool$CullTask.run(BasicResourcePool.java:1937)
at java.util.TimerThread.mainLoop(Timer.java:555)
at java.util.TimerThread.run(Timer.java:505)

怪我咯怪我咯2743 days ago438

reply all(2)I'll reply

  • 伊谢尔伦

    伊谢尔伦2017-04-18 10:54:12

    If you think there is no problem with the code, you can try changing to a different version of tomcat, such as 8.0 or 8.5.

    Tomcat9 seems to have some problems at the moment. I tried it two weeks ago and it can’t run

    reply
    0
  • 伊谢尔伦

    伊谢尔伦2017-04-18 10:54:12

    tomcat reports an exception Illegal access: this web application instance has been stopped already. Could not load exception information cannot reflect the root cause of the system startup failure. When encountering such exceptions, many developers may be a little overwhelmed because they don't know where the problem occurs. Here is a trick to help you accurately locate the reason why the tomcat system fails to start.

    1. Prepare a configuration file, the name must be: logging.properties.
    The content of the file is as follows:

    handlers = org.apache.juli.FileHandler, java.util.logging.ConsoleHandler      
    
    org.apache.juli.FileHandler.level = FINE    
    org.apache.juli.FileHandler.directory = ${catalina.home}/logs/tomcat.log  
    org.apache.juli.FileHandler.prefix = error-debug.    
         
    java.util.logging.ConsoleHandler.level = FINE    
    java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
    1. Place this file logging.properties under web-inf/classes of the java web project

    2. Restart Tomcat
      At this time, you will find that tomcat automatically prints more useful exception information. By analyzing these newly printed abnormal information, you can immediately locate the problem.

    reply
    0
  • Cancelreply