启动tomcat后重新部署报错
信息: Illegal access: this web application instance has been stopped already.? Could not load java.net.BindException.? 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:1273)
?at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1233)
?at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
?at com.mysql.jdbc.CommunicationsException.<init>(CommunicationsException.java:155)
?at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:2652)
?at com.mysql.jdbc.MysqlIO.quit(MysqlIO.java:1345)
?at com.mysql.jdbc.Connection.realClose(Connection.java:4784)
?at com.mysql.jdbc.Connection.cleanup(Connection.java:2040)
?at com.mysql.jdbc.Connection.finalize(Connection.java:3296)
?at java.lang.ref.Finalizer.invokeFinalizeMethod(Native Method)
?at java.lang.ref.Finalizer.runFinalizer(Finalizer.java:83)
?at java.lang.ref.Finalizer.access$100(Finalizer.java:14)
?at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:160)
2010-1-22 10:19:45 org.apache.catalina.loader.WebappClassLoader loadClass
信息: Illegal access: this web application instance has been stopped already.? Could not load com.mysql.jdbc.Util.? 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:1273)
?at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1233)
?at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
?at com.mysql.jdbc.CommunicationsException.<init>(CommunicationsException.java:180)
?at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:2652)
?at com.mysql.jdbc.MysqlIO.quit(MysqlIO.java:1345)
?at com.mysql.jdbc.Connection.realClose(Connection.java:4784)
?at com.mysql.jdbc.Connection.cleanup(Connection.java:2040)
?at com.mysql.jdbc.Connection.finalize(Connection.java:3296)
?at java.lang.ref.Finalizer.invokeFinalizeMethod(Native Method)
?at java.lang.ref.Finalizer.runFinalizer(Finalizer.java:83)
?at java.lang.ref.Finalizer.access$100(Finalizer.java:14)
?at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:160)
?
解决:
找到tomcat的server.xml文件,找到下面一段
<Host name="localhost"? appBase="webapps"
??????????? unpackWARs="true" autoDeploy="true"
??????????? xmlValidation="false" xmlNamespaceAware="false">
????? </Host>
替换
<Host name="localhost"? appBase="webapps"
??????????? unpackWARs="true" autoDeploy="false"
??????????? xmlValidation="false" xmlNamespaceAware="false">
????? </Host>