Unable to load libjvm

Trying to do a “dvc pull …” I get

ERROR: unexpected error - Unable to load libjvm: /usr/java/latest//lib/amd64/server/libjvm.so: cannot open shared object file: No such file or directory               

Because JAVA wasn’t installed:

sudo apt install openjdk-17-jre-headless

Now, there is a libjvm.so and so I’ve created the following environment varible

export LD_LIBRARY_PATH=/usr/lib/jvm/java-17-openjdk-amd64/lib/server

Unfortunately the error still persists. Do you have an idea of how to fix this?

Many thanks, Thomas

Hi @TJC ! Can you share the output of dvc pull -v and dvc doctor?

Thanks @daavoo for taking care… We have just found out that a missing JAVA_HOME environment variable was the reason. So with…

export JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

dvc pull is working fine now.