码迷,mamicode.com
首页 > 其他好文 > 详细

Tomcat: Can't load IA 32-bit .dll on a AMD 64-bit platform问题的解决

时间:2014-10-21 13:48:32      阅读:238      评论:0      收藏:0      [点我收藏+]

标签:style   blog   http   color   io   ar   java   for   sp   

 

控制台错误如下:

java.lang.UnsatisfiedLinkError: D:\apache-tomcat-7.0.56\bin\tcnative-1.dll: Can‘t load IA 32-bit .dll on a AMD 64-bit platform

    at java.lang.ClassLoader$NativeLibrary.load(Native Method)
    at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1778)
    at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1703)
    at java.lang.Runtime.loadLibrary0(Runtime.java:823)
    at java.lang.System.loadLibrary(System.java:1030)
    at org.apache.tomcat.jni.Library.<init>(Library.java:42)
    at org.apache.tomcat.jni.Library.initialize(Library.java:174)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.catalina.core.AprLifecycleListener.init(AprLifecycleListener.java:179)
    at org.apache.catalina.core.AprLifecycleListener.isAprAvailable(AprLifecycleListener.java:84)
    at org.apache.catalina.connector.Connector.setProtocol(Connector.java:567)
    at org.apache.catalina.connector.Connector.<init>(Connector.java:69)
    at org.apache.catalina.startup.ConnectorCreateRule.begin(ConnectorCreateRule.java:62)
    at org.apache.tomcat.util.digester.Digester.startElement(Digester.java:1276)
    at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:501)
    at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:179)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1339)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2747)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:648)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:807)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)
    at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:107)
    at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205)
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
    at org.apache.tomcat.util.digester.Digester.parse(Digester.java:1537)

    at org.apache.catalina.startup.Catalina.load(Catalina.java:555)
    at org.apache.catalina.startup.Catalina.load(Catalina.java:598)

    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.catalina.startup.Bootstrap.load(Bootstrap.java:281)
    at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:449)

问题原因:

在64位系统下安装的jdk是64位(虚拟机也就是64位)的,而根据报的错误是不能在64位系统下加载64位的虚拟机,只能加载32位的。

解决办法:

1.下载一个32位的替换   http://www.apache.org/dist/tomcat/tomcat-connectors/native/1.1.31/binaries/

bubuko.com,布布扣

2.将下载下来的文件解压,找到x64文件夹下的tcnative-1.dll文件

bubuko.com,布布扣

3.替换tomcat中bin文件夹下的tcnative-1.dll文件

bubuko.com,布布扣

Tomcat: Can't load IA 32-bit .dll on a AMD 64-bit platform问题的解决

标签:style   blog   http   color   io   ar   java   for   sp   

原文地址:http://www.cnblogs.com/doublesauce/p/4040095.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!