Error java.lang.UnsatisfiedLinkError when loading Java SDK on Development server

345
1
Jump to solution
07-23-2020 06:28 AM
RafaelFreitas
New Contributor II

Hello!

I have followed this tutorial (Get the SDK—ArcGIS Runtime SDK for Java | ArcGIS for Developers ) to setup with maven the ArcGis SDK on my local environment and it is working fine.

I am trying to deploy this application on an EC2 server from AWS. I can generate the .jar with "mvn clean install" and execute it on server with "java -jar <name>.jar". I have also sent the files generated from dependency:unpack to the server, and added them to /home/<user>/.arcgis and also to the folder that my application is running. 

However, when I try to use functionalities that depends on arcgis I get the error:

java.lang.UnsatisfiedLinkError: /var/www/u/jniLibs/LX64/libruntimecore_java.so: libGL.so.1: cannot open shared object file: No such file or directory

This file exists on this path, and if I give all permissions to this folder with chmod the error is:

java.lang.NoClassDefFoundError: Could not initialize class com.esri.arcgisruntime.geometry.SpatialReferences

How can I fix this? Thanks!!

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
RafaelFreitas
New Contributor II

For anyone having the same issue, I solved with this:

sudo apt update 
sudo apt install libgl1-mesa-glx

View solution in original post

0 Kudos
1 Reply
RafaelFreitas
New Contributor II

For anyone having the same issue, I solved with this:

sudo apt update 
sudo apt install libgl1-mesa-glx

View solution in original post

0 Kudos