Skip to content

Instantly share code, notes, and snippets.

@filipsPL
Created June 15, 2020 11:49
Show Gist options
  • Save filipsPL/fc2e351a2cf0baeda45c2957d652ec96 to your computer and use it in GitHub Desktop.
Save filipsPL/fc2e351a2cf0baeda45c2957d652ec96 to your computer and use it in GitHub Desktop.
[solved] Unable to start h2o AI java jar: Boot class path mechanism is not supported

the problem

when running h2o.ai:

java -jar h2o.jar

there is an error:

06-15 13:26:18.086 192.168.12.198:54321    19409  main      INFO: ----- H2O started  -----
06-15 13:26:18.121 192.168.12.198:54321    19409  main      INFO: Build git branch: master
06-15 13:26:18.122 192.168.12.198:54321    19409  main      INFO: Build git hash: 74c5d489ce5e7e6e2fd1cccdd977a16d53a7a377
06-15 13:26:18.122 192.168.12.198:54321    19409  main      INFO: Build git describe: jenkins-master-3501
06-15 13:26:18.122 192.168.12.198:54321    19409  main      INFO: Build project version: 3.9.1.3501
...
Exception in thread "main" java.lang.UnsupportedOperationException: Boot class path mechanism is not supported
        at java.management/sun.management.RuntimeImpl.getBootClassPath(RuntimeImpl.java:99)
        at water.H2O.main(H2O.java:1810)
        at water.H2OStarter.start(H2OStarter.java:21)
        at water.H2OStarter.start(H2OStarter.java:36)
        at water.H2OApp.main(H2OApp.java:5)

the solution

This is because of the too-new version of java. To get rid of this error and run h2o.jar, install an older verison of jre, for example by apt (debian, ubuntu, mint):

apt install openjdk-8-jre-headless

or in conda virtual environment:

conda install openjdk=8.0.152

make sure that you run h2o.jar by the good (old) version of java:

$ which java
/home/user/miniconda2/envs/env1/bin/java

$ java -version
openjdk version "1.8.0_152-release"
OpenJDK Runtime Environment (build 1.8.0_152-release-1056-b12)
OpenJDK 64-Bit Server VM (build 25.152-b12, mixed mode)

$ java -jar h2o.jar

(h2o runs without errors!)

good luck!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment