SpringBoot启动项目报错:java.lang.UnsatisfiedLinkError: D:\files\software\jdk-15.0.1\jdk-17.0.3.1\bin\tcnative-1.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform
问题描述
在运行向的时候出现报错:
java.lang.UnsatisfiedLinkError: D:\files\software\jdk-15.0.1\jdk-17.0.3.1\bin\tcnative-1.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform
at java.base/jdk.internal.loader.NativeLibraries.load(Native Method) ~[na:na]
at java.base/jdk.internal.loader.NativeLibraries$NativeLibraryImpl.open(NativeLibraries.java:388) ~[na:na]
at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:232) ~[na:na]
at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:174) ~[na:na]
at java.base/jdk.internal.loader.NativeLibraries.findFromPaths(NativeLibraries.java:315) ~[na:na]
at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:285) ~[na:na]
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2422) ~[na:na]
at java.base/java.lang.Runtime.loadLibrary0(Runtime.java:818) ~[na:na]
at java.base/java.lang.System.loadLibrary(System.java:1989) ~[na:na]
at org.apache.tomcat.jni.Library.<init>(Library.java:69) ~[tomcat-embed-core-9.0.46.jar:9.0.46]
at org.apache.tomcat.jni.Library.initialize(Library.java:206) ~[tomcat-embed-core-9.0.46.jar:9.0.46]
at org.apache.catalina.core.AprLifecycleListener.init(AprLifecycleListener.java:193) ~[tomcat-embed-core-9.0.46.jar:9.0.46]
at org.apache.catalina.core.AprLifecycleListener.isAprAvailable(AprLifecycleListener.java:102) ~[tomcat-embed-core-9.0.46.jar:9.0.46]
at org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory.getDefaultLifecycleListeners(TomcatServletWebServerFactory.java:173) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.web.embedded.tomcat.TomcatServletWebServerFactory.<init>(TomcatServletWebServerFactory.java:120) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.autoconfigure.web.servlet.ServletWebServerFactoryConfiguration$EmbeddedTomcat.tomcatServletWebServerFactory(ServletWebServerFactoryConfiguration.java:76) ~[spring-boot-autoconfigure-2.5.0.jar:2.5.0]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:na]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) ~[na:na]
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:na]
at java.base/java.lang.reflect.Method.invoke(Method.java:568) ~[na:na]
at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:653) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:638) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1334) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:213) ~[spring-beans-5.3.7.jar:5.3.7]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.getWebServerFactory(ServletWebServerApplicationContext.java:217) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.createWebServer(ServletWebServerApplicationContext.java:180) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.onRefresh(ServletWebServerApplicationContext.java:160) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:577) ~[spring-context-5.3.7.jar:5.3.7]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:145) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:758) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:337) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1336) ~[spring-boot-2.5.0.jar:2.5.0]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1325) ~[spring-boot-2.5.0.jar:2.5.0]
at com.kailong.KaiLongBlogApplication.main(KaiLongBlogApplication.java:12) ~[classes/:na]
在网上查了之后有一个说是决定考与tomcat位数不一致:
原贴地址:https://www.cnblogs.com/yuxiaole/p/9247610.html
后检查jdk与tomcat
jdk检查命令:java -version
tomcat检查命令:catalina version
输出信息中,Architecture:字段的值就是tomcat的位数
检查后发现均为64位
最后发现是idea的spring项目有默认的包路径 与实际的存在差异
解决方法:
加上-Djava.library.path=/usr/local/java/lib:/usr/local/hadoop/lib
就好了
SpringBoot启动项目报错:java.lang.UnsatisfiedLinkError: D:\files\software\jdk-15.0.1\jdk-17.0.3.1\bin\tcnative-1.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform的更多相关文章
- 解决:启动项目报错 java.lang.UnsatisfiedLinkError: D:\Java\apache-tomcat-8.0.17\bin\tcnative-1.dll: Can't load IA 32-bit .dll on a AMD 64-bit platform
启动项目报错如下: java.lang.UnsatisfiedLinkError: D:\Java\apache-tomcat-8.0.17\bin\tcnative-1.dll: Can't loa ...
- tomcat7 启动项目报错 java.lang.NoSuchMethodError: javax.servlet.ServletContext.getSessionCookieConfig()
JDK版本:jdk1.8.0_77 Tomcat 版本:apache-tomcat-7.0.47 异常重现步骤: 1.完成项目部署 2.启动Tomcat 异常头部信息:java.lang.NoSuch ...
- 解决:启动项目报错 java.lang.NoClassDefFoundError: org/apache/commons/fileupload/FileItemFactory
前言:项目在 spring-mvc.xml 文件中配置了上传文件拦截,结果启动报错 java.lang.NoClassDefFoundError: org/apache/commons/fileupl ...
- Tomcat 启动项目报错 java.lang.OutOfMemoryError: Java heap space
近日使用myeclipse 部署web项目,启动tomcat时报错: SEVERE: Error waiting for multi-thread deployment of directories ...
- springboot启动tomcat报错java.lang.NoClassDefFoundError: javax/el/ELManager仅记录
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'o ...
- eclipse 启动项目 报错 java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderLis(亲测)
[原因] 重新 clean 和 install 了maven项目后就启动报错了.解决如下: 右键项目: 属性properties 删除掉引用的其他jar 选择 Deployment Assembl ...
- 项目报错java.lang.ClassNotFoundException: org.common.SessionListener
现象:项目报错java.lang.ClassNotFoundException: org.common.SessionListener,并且myeclipse左侧Package Explorer中项目 ...
- maven 项目启动tomcat报错 java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
maven项目启动tomcat报错: java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderLi ...
- Tomcat启动报错java.lang.UnsatisfiedLinkError
之前tomcat启动老是报错,虽然不影响项目的启动运行,但是有强迫症的程序员会心里不爽: 问题是由于本机安装的jdk版本与tomcat中使用的jdk版本不一致导致的. 后面我把原先tomcat启动环境 ...
- resin下发布项目报错java.lang.NoSuchMethodError: javax.persistence.Table.indexes()[Ljavax/persistence/Index
我的resin版本为4.0.56; 项目在tomcat下启动正常,打包在resin下发布时报错:java.lang.NoSuchMethodError: javax.persistence.Table ...
随机推荐
- Webpack5
Webpack是一款模块打包工具,可以把多个文件打包成一个或几个文件,它不仅能打包JS文件, 还能打包css, image等静态资源.当然,在默认情况下,它只打包JS文件和JSON文件,因为它只认识J ...
- Ubuntu 查看用户历史记录
Ubuntu 查看用户历史记录 1. 查看用户命令行历史记录 1. 查看当前登录账号所属用户的历史命令行记录 打开命令行,输入 history 就会看到当前登录账号所属用户的历史记录 2. 查看系统所 ...
- python爬取网站图片保存到本地文件夹
爬取的网站 https://wallpaperscraft.com/catalog/anime 爬取代码 # 导包 import os import requests import parsel fr ...
- 类、事件与对象---Dad&Mom&Friends(进阶事件)
接上一个笔记:https://www.cnblogs.com/StephenYoung/p/17792668.html 现在增加了一个新的朋友类:Friends 这个类构造如下: 从上到下依次是: 1 ...
- 全网最适合入门的面向对象编程教程:13 类和对象的Python实现-可视化阅读代码神器Sourcetrail的安装使用
全网最适合入门的面向对象编程教程:13 类和对象的 Python 实现-可视化阅读代码神器 Sourcetrail 的安装使用 摘要: 本文主要介绍了可视化阅读代码神器Sourcetrail的安装与使 ...
- 全网最适合入门的面向对象编程教程:17 类和对象的Python实现-鸭子类型与“file-like object“
全网最适合入门的面向对象编程教程:17 类和对象的 Python 实现-鸭子类型与"file-like object" 摘要: 本文主要介绍了 Python 中创建自定义类时鸭子类 ...
- CF1363A 题解
洛谷链接&CF 链接 题目简述 共有 \(T\) 组数据. 对于每组数据,给定 \(n,x\) 和 \(n\) 个数,问是否可以从 \(n\) 个数中选 \(x\) 个使其和为奇数,可以输出 ...
- ASP.NET Core 程序集注入(三)
前言: 在Autofac的使用中,提供了个种注入的API其中GetAssemblies()用着特别的舒坦. 1.core2.0也可以使用Autofac的包,但框架自身也提供了默认的注入Api,ISer ...
- TIER 1: Crocodile
TIER 1: Crocodile nmap 在前几次练习中,我们已经熟悉 nmap 扫描,我们在本次靶机中使用继续使用 nmap 进行扫描. 扩充我们的知识库:-sC 选项启用了 Nmap 的默认脚 ...
- Pytest Pytest源码分析
Pytest源码分析 By:授客 QQ:1033553122 测试环境 pytest 5.4.3 测试脚本mytest.py #!/usr/bin/env python # -*- coding:ut ...