首页 > 技术文章 > IDEA启动tomcat时提示:...init The APR based Apache Tomcat Native library failed to load. The error reported was ...tcnative-1.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform

acmexyz 2020-03-13 16:02 原文

 

警告 [main] org.apache.catalina.core.AprLifecycleListener.init The APR based Apache Tomcat Native library failed to load. The error reported was [C:\Windows\System32\tcnative-1.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform] java.lang.UnsatisfiedLinkError: C:\Windows\System32\tcnative-1.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform at java.lang.ClassLoader$NativeLibrary.load(Native Method)

 

原因是tomcat可移植运行库在C:\Windows\System32目录里缺少一个tcnative-1.dll文件;解决方法如下:

 

* 打开tomcat官网:http://tomcat.apache.org/

 

 

 

使用的是tomcat8.5,且报错信息提示的version是1.2,所以下载这个文件:

 

 

 

下载好后解压,打开bin文件夹,根据系统是32位还是64位,选择相应的tcnative-1.dll文件

 

 

 

 之后将该文件复制到 C:\Windows\System32 下面即可,重启tomcat不再出现报错信息。

推荐阅读