Ubuntu 18.04 LTS- How to set the default-jre with a specific version?

I would like to install on Ubuntu 18.04 LTS an application that requires java 8. When I want to install this application, an error is raised about the default-jre:

Package default-jre is not configured yet

However, when I tried java - version, the java version returned is openjdk version 1.8.0_191

Please note, I don't want the version 10 or 11 of java.

So, do you know how to solve this issue?

1 Answer

You may use the following command to install OpenJDK 8:

sudo apt install openjdk-8-jdk

And check the version with:

java -version
3

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like