0
Answered

Cannot start Ubooquity from command line

Black Six 4 years ago updated 4 years ago 2

I'm running Ubooquity on a Mac mini. Generally it works fine but periodically it will crash requiring me to go and restart it. I'm trying to set up a cron job to check on it every so often and restart if need be but am running into a problem.


If I double-click Ubooquity.jar from the OS X GUI it launches fine. If I try to start it via Terminal though, I get this:


Computer:Ubooquity user$ java -jar Ubooquity.jar -webadmin
Exception in thread "main" java.lang.UnsupportedClassVersionError: com/ubooquity/Launcher : Unsupported major.minor version 52.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClassCond(ClassLoader.java:637)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)


Any ideas?

Answered

This error means that your Java version is too old (Ubooquity needs Java 8).


You probably have several different versions of Java on your Mac Mini (since Ubooquity is working when you double click on the jar).


You can work around this problem either by:

- changing the version of Java in your path

- or by using the full path to your Java binary instead of just using "java"

Thanks! I was able to uninstall the old Apple JDK 1.6 and get JDK 1.8 installed. It works now!