Tomcat 服务器(来自 XAMPP 包)无法从 Eclipse 启动
我使用的是 Windows 7。我安装了 Eclipse 并更新为包含 WPT。 HTTP Server 和 Tomcat 随 XAMPP 软件包一起安装。它们运行正常并且可以通过本地主机访问。
但是我发现tomcat服务器无法启动。 Eclipse总是报启动失败。
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:412)
Caused by: java.lang.UnsatisfiedLinkError: org.apache.tomcat.jni.Pool.create(J)J
at org.apache.tomcat.jni.Pool.create(Native Method)
at org.apache.tomcat.util.net.AprEndpoint.init(AprEndpoint.java:589)
at org.apache.coyote.http11.Http11AprProtocol.init(Http11AprProtocol.java:107)
at org.apache.catalina.connector.Connector.initialize(Connector.java:1058)
at org.apache.catalina.core.StandardService.initialize(StandardService.java:677)
at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:795)
at org.apache.catalina.startup.Catalina.load(Catalina.java:535)
at org.apache.catalina.startup.Catalina.load(Catalina.java:555)
... 6 more*
有什么我可以检查的吗?
I am using Windows 7. I installed Eclipse and updated to include WPT. HTTP Server and Tomcat are installed with XAMPP Package. They run properly and they can be accessed via localhost.
But I found that tomcat server cannot be started. Eclipse always reports failed to start.
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:412)
Caused by: java.lang.UnsatisfiedLinkError: org.apache.tomcat.jni.Pool.create(J)J
at org.apache.tomcat.jni.Pool.create(Native Method)
at org.apache.tomcat.util.net.AprEndpoint.init(AprEndpoint.java:589)
at org.apache.coyote.http11.Http11AprProtocol.init(Http11AprProtocol.java:107)
at org.apache.catalina.connector.Connector.initialize(Connector.java:1058)
at org.apache.catalina.core.StandardService.initialize(StandardService.java:677)
at org.apache.catalina.core.StandardServer.initialize(StandardServer.java:795)
at org.apache.catalina.startup.Catalina.load(Catalina.java:535)
at org.apache.catalina.startup.Catalina.load(Catalina.java:555)
... 6 more*
Is there anything that I can check ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您正在使用 HTTP 1.1 APR 协议(或者至少, XAMPP 已将其 Tomcat 实例配置为默认使用 APR)。这依赖于应包含在环境变量
%PATH%
中的本机库。如果无法解析这些本机库,您将收到java.lang.UnsatisfiedLinkError
。因此,要解决此问题,您需要将 APR 库的路径添加到
%PATH%
中,或者更改server.xml
中的 HTTP 连接器 使用标准实现< code>HTTP/1.1 或 NIO 实现org.apache.coyote.http11.Http11NioProtocol
。You're using the HTTP 1.1 APR protocol (or at least, XAMPP has configured its Tomcat instance to use APR by default). This has dependencies on native libraries which should be included in the environment variable
%PATH%
. If those native libraries cannot be resolved, you'll get anjava.lang.UnsatisfiedLinkError
.So to fix this issue, you need to add the path to the APR libraries to the
%PATH%
or to change theprotocol
attribute of the HTTP connector inserver.xml
to use the standard implementationHTTP/1.1
or the NIO implementationorg.apache.coyote.http11.Http11NioProtocol
.