'docker sql error - invalid ELF header (Possible cause: endianness mismatch)
My docker file contains:
FROM maven:3.8.5-adoptopenjdk-11
WORKDIR /Project
COPY /Proj_Copy/ /Project/
CMD ["java", "-jar", "/Project/test.jar", "excel", "/Project/."]
Within my test.jar file, we interact with SQL queries and I am packaging 64bit dll files along with my other project files and pointing my code to that jar within container. I keep getting the following error:
OpenJDK 64-Bit Server VM warning: You have loaded library /Project/jars/sqljdbc_auth.dll which might have disabled stack guard. The VM will try to fix the stack guard now.
It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'.
Exception in thread "main" java.lang.UnsatisfiedLinkError: /Project/jars/sqljdbc_auth.dll: /Project/jars/sqljdbc_auth.dll: invalid ELF header (Possible cause: endianness mismatch)
at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method)
at java.base/java.lang.ClassLoader$NativeLibrary.load(ClassLoader.java:2442)
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
