Java报错01
spingboot启动报错
java.lang.UnsatisfiedLinkError: no tcnative-1 in java.library.path
问题
java.lang.UnsatisfiedLinkError: no tcnative-1 in java.library.path
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2541) ~[na:na]
at java.base/java.lang.Runtime.loadLibrary0(Runtime.java:873) ~[na:na]
at java.base/java.lang.System.loadLibrary(System.java:1857) ~[na:na]
at org.apache.tomcat.jni.Library.<init>(Library.java:69) ~[tomcat-embed-core-9.0.21.jar:9.0.21]
at org.apache.tomcat.jni.Library.initialize(Library.java:206) ~[tomcat-embed-core-9.0.21.jar:9.0.21]
原因
-
缺少了tcnative-1.dll。
-
或者因为tcnative-1.dll的位数不对。
注:.dll存储地址 (C:\Windows\System32)
(可能是tomcat 9缺少文件)
解决方法
)
添加
-Djava.library.path=/usr/local/java/lib:/usr/local/hadoop/lib
原文地址:https://blog.csdn.net/weixin_41269213/article/details/107815643
## spingboot启动报错 ## java.lang.UnsatisfiedLinkError: no tcnative-1 in java.library.path