【问题标题】:An incompatible version 1.1.12 of the APR based Apache Tomcat Native library is installed, while Tomcat requires version 1.1.17安装了基于 APR 的 Apache Tomcat Native 库的不兼容版本 1.1.12,而 Tomcat 需要版本 1.1.17
【发布时间】:2011-06-15 02:10:48
【问题描述】:

我下载了 Apache Tomcat 7.x。当我在 Eclipse 中添加这个 Tomcat 时,我得到了这个错误:

Jan 25, 2011 3:21:05 PM org.apache.catalina.core.AprLifecycleListener init
SEVERE: An incompatible version 1.1.12 of the APR based Apache Tomcat Native library is installed, while Tomcat requires version 1.1.17 
Jan 25, 2011 3:21:05 PM org.apache.catalina.core.AprLifecycleListener init
SEVERE: An incompatible version 1.1.12 of the APR based Apache Tomcat Native library is installed, while Tomcat requires version 1.1.17 
Jan 25, 2011 3:21:05 PM org.apache.catalina.core.AprLifecycleListener init
SEVERE: An incompatible version 1.1.12 of the APR based Apache Tomcat Native library is installed, while Tomcat requires version 1.1.17 
Jan 25, 2011 3:21:05 PM org.apache.catalina.core.AprLifecycleListener init
SEVERE: An incompatible version 1.1.12 of the APR based Apache Tomcat Native library is installed, while Tomcat requires version 1.1.17 
Jan 25, 2011 3:21:05 PM org.apache.catalina.core.AprLifecycleListener init
SEVERE: An incompatible version 1.1.12 of the APR based Apache Tomcat Native library is installed, while Tomcat requires version 1.1.17 
Jan 25, 2011 3:21:08 PM org.apache.coyote.AbstractProtocolHandler init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Jan 25, 2011 3:21:08 PM org.apache.coyote.AbstractProtocolHandler init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Jan 25, 2011 3:21:08 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 3054 ms
Jan 25, 2011 3:21:08 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Jan 25, 2011 3:21:08 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.6
Jan 25, 2011 3:21:08 PM org.apache.coyote.AbstractProtocolHandler start
INFO: Starting ProtocolHandler ["http-bio-8080"]
Jan 25, 2011 3:21:08 PM org.apache.coyote.AbstractProtocolHandler start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
Jan 25, 2011 3:21:08 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 251 ms

我该如何解决这个问题?

当我打开localhost:8080/manager/html 时,它显示以下错误:

HTTP Status 404 - /manager/html

type Status report

message /manager/html

description The requested resource (/manager/html) is not available.
Apache Tomcat/7.0.6

【问题讨论】:

    标签: java eclipse tomcat tomcat7


    【解决方案1】:

    第一个错误听起来像是版本不匹配。 APR 库是在运行时根据您的路径链接的库(它本身可以基于您执行 Tomcat 的位置)。听起来你有 Tomcat 6 的 APR 库。Eclipse 可能提供了这个 APR 库。

    Tomcat 附带一个 APR 库,但为了简化安装,Tomcat 不会自动修改指向 APR 库的路径。 Eclipse Tomcat 集成可能(我不确定这一点,以前没有使用过集成)包含 APR 库,以便更轻松地使用 Tomcat。

    检查并确保 Eclipse 未配置为使用早期版本的 Tomcat,如果是,请将 Eclipse 升级到 Tomcat 7 或将 Tomcat 降级到 Eclipse 中指定的版本。

    如果您无法弄清楚,那么您现在不必担心它。 Tomcat 应该在没有 APR 库的情况下仍然可以工作。您将从 APR 库中获得的唯一好处是提高了性能,因为这可能是您项目的开始,不必立即解决。

    第二个问题,/manager/ 页面,可能是 Tomcat 配置。除非用户配置了manager permissions,否则 Tomcat 不会真正显示管理器页面(它会给你这个错误)。

    尝试只使用 /(即http://localhost:8080),无论用户配置如何,该页面都应该加载。

    【讨论】:

      【解决方案2】:

      就我而言,当我使用包管理器在我的 Linux 上本地安装一次 Tomcat 时,我无意中安装了 APR 库。在 Debian/Ubuntu 上,这为导致此错误的不同 Tomcat 版本(与您的发行版捆绑的版本)安装了 APR 包。

      简单之后

      sudo apt-get purge libtcnative-1
      

      错误消失了。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2018-07-14
        • 2023-01-16
        • 2011-05-15
        • 2013-09-19
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2013-06-06
        相关资源
        最近更新 更多