zoukankan      html  css  js  c++  java
  • Tomcat启动报错误,打开详细debug

    今天tomcat启动加载项目时,报以下错:

    09-Nov-2016 11:43:35.815 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal One or more listeners failed to start. Full details w ill be found in the appropriate container log file 41
    09-Nov-2016 11:43:35.817 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal Context [/demo] startup failed due to previous errors

    怎么都解决不了,tomcat报的错又太简略啥都看不出。

    用以下方法可以让tomcat打出详细错误信息

    可以在WEB-INF/classes目录下新建一个文件叫logging.properties

    内容为:

    handlers = org.apache.juli.FileHandler, java.util.logging.ConsoleHandler  
    
    ############################################################  
    # Handler specific properties.  
    # Describes specific configuration info for Handlers.  
    ############################################################  
    
    org.apache.juli.FileHandler.level = FINE  
    org.apache.juli.FileHandler.directory = ${catalina.base}/logs  
    org.apache.juli.FileHandler.prefix = error-debug.  
    
    java.util.logging.ConsoleHandler.level = FINE  
    java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFor
    matter  

    我们再启动tomcat时,就会在logs目录下生成一个更详细的日志error-debug.*.log。
    既可以看到详细的错误信息,然后再根据错误信息修改就好了。

  • 相关阅读:
    解决PHP下打开phpMyAdmin出现403错误 Jimmy
    SQL Server连接中三个常见的错误分析
    CD唱片格式知识
    ehlib的DBGridEh控件中使用过滤功能的方法
    TransactSQL MSDN入口
    发烧音响网站大全
    Transact SQL 语 句 功 能
    wwFilterDialog 取得條件
    器材价格 参考用
    phpadmin.config设定
  • 原文地址:https://www.cnblogs.com/A-yes/p/9894173.html
Copyright © 2011-2022 走看看