Error injecting constructor StardogKernel

I have the same/similar problem as this call Problems installing Stardog, although I think the install is OK. Just starting the server doesn't work.

I get this when running stardog-admin server start

Unable to provision, see the following errors:

  1. Error injecting constructor, java.lang.ExceptionInInitializerError
    at com.complexible.stardog.StardogKernel.(
    at com.complexible.stardog.StardogKernel.class(
    while locating com.complexible.stardog.StardogKernel
    while locating com.complexible.stardog.Kernel

I do have both Java 8 and Java 11 installed on my machine

jenv versions


  • 1.8 (set by /Users/derek/opt/stardog-7.1.1/bin/.java-version)

I inserted some echo statements in stardog-admin to check the version being used. I added the following -
echo java -version

The output was -
openjdk version "1.8.0_242"
OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_242-b08)
OpenJDK 64-Bit Server VM (AdoptOpenJDK)(build 25.242-b08, mixed mode)

-Dstardog.home=/Users/derek/data/StardogHome/ -Xmx512m -Djava.library.path=/Users/derek/opt/stardog-7.1.1/bin/../lib

It looks like it's running the right version of java. So, why is it giving this error when starting?

OK. I've dug a little deeper. I seem to be able to call other java programs from here. I have been using jenvs to manage my java environments. I noticed that the JAVA_HOME had not been set. I set that to the install for Java8 and the script now started the servers

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.