0

I have downloaded the installation files of the ant media server and now I am following this tutorial to try to run the server.
So I've run this command:

./start.sh

But, I keep getting this error:

Exception in thread "main" java.lang.UnsupportedClassVersionError: org/red5/server/Bootstrap has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 53.0

Here's the whole stack trace:
enter image description here

Running java -version gives me this:
enter image description here

Running javac -version gives me this:
enter image description here

The OS info is:
enter image description here

Any idea what's going-on?


I have tried installing java 8 by following the commands here:
enter image description here
So now when I run java -version, I get this:
enter image description here
But, I still get the same error.


FYI, when I run this command:

sudo update-alternatives --config java

This is what I get:
enter image description here
I have selected option 1. I have run the same commands for javac.
So now when I run java -version, I have this:
enter image description here
And when I run javac -version, I have this:
enter image description here
And I am still getting the same error.


The JAVA_HOME environment variable is also set to:

JAVA_HOME=/usr/lib/jvm/java-8-oracle

2
  • 1
    Your application includes JAR files built for Java 11. (version 55). You should be running the application using a Java 11 (or later) JVM. Java 8 (version 52) won't work. And nor will Java 9 (version 53).
    – Stephen C
    Commented Mar 11, 2021 at 7:59
  • 2
    And ... on re-reading your question ... it is not "your" application. It is a 3rd-party application whose installation instructions neglect to say that it requires Java 11. (This isn't really a programming question at all.)
    – Stephen C
    Commented Mar 11, 2021 at 8:07

1 Answer 1

1

The error is telling you that the class was compiled with a newer version than the one you're running.

You need to run it with Java 11 (version 55) but you are using Java 9 (version 53).

0

Not the answer you're looking for? Browse other questions tagged or ask your own question.