Usually you install the openjdk like this:

sudo apt-get install openjdk-8-jdk

Maybe this is the problem. You can look this up at http://openjdk.java.net/install/index.html. If you do this you might have fixed this problem. But cant imagine why your command give this result.

Answer from Booming on askubuntu.com
🌐
Oracle
java.com › en › download › help › linux_x64_install.html
Linux 64-bit installation instructions for Java
Move the .tar.gz archive binary to the current directory. Unpack the tarball and install Java tar zxvf jre-8u73-linux-x64.tar.gz The Java files are installed in a directory called jre1.8.0_73 in the current directory. In this example, it is installed in the /usr/java/jre1.8.0_73 directory.
Discussions

How do I install Java 8 JRE
I'd suggest you run sudo apt update; sudo apt list | grep jre to find the package name. I do remember that the JRE and JDK package names are often confusing, so that's why I'm recommending this approach. More on reddit.com
🌐 r/linux4noobs
8
2
May 30, 2023
How to install Java 8 on Alpine Linux? - Unix & Linux Stack Exchange
When I look at package lists they suggest that all sorts of Java 8 packages exist for Alpine, but when I try to install them I always get: apk add openjdk8 ERROR: unsatisfiable constraints: open... More on unix.stackexchange.com
🌐 unix.stackexchange.com
December 12, 2019
Linux Java 8 Installation

But when i type in sudo apt-get install openjdk-8-jre it doesn't work

More on reddit.com
🌐 r/linuxquestions
3
1
April 9, 2021
need help installing java 8 on ubuntu server
Try running "sudo apt-get install default-jre" (without the quotes of course). This should install some version of the Java 8 runtime. Though I should tell you that if you are hosting a Minecraft 1.18/1.17 server, you will need Java 17 or above installed. If you're doing a version below 1.17, try the command I said above. More on reddit.com
🌐 r/Ubuntu
4
3
April 3, 2022
🌐
GitHub
gist.github.com › wagyourtail › b115f66d135b3818b63d9b27048d80e6
Installing Java 8 on various Linux distros · GitHub
Download the jre tar.gz (Linux Compressed Archive) from Oracle's Website or the Java Website. make sure to select the correct x86 / x64 for your Architecture, it's probably x64 if your computer's newer than 2005.
🌐
Oracle
docs.oracle.com › javase › 8 › docs › technotes › guides › install › install_overview.html
JDK 8 and JRE 8 Installation Start Here
April 21, 2026 - This page gives access to instructions for installing the JDK and JRE on Oracle Solaris, Windows, Linux, and macOS computers.
🌐
Linux Mint Forums
forums.linuxmint.com › board index › debian edition support › lmde forums › lmde archive
Installing OpenJDK8 - Linux Mint Forums
Done Building dependency tree Reading state information... Done ca-certificates-java is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. person@computer ~ $ sudo apt-get install openjdk-8-jre-headless Reading package lists...
🌐
Red Hat
docs.redhat.com › en › documentation › red_hat_build_of_openjdk › 8 › html › installing_and_using_red_hat_build_of_openjdk_8_for_rhel › assembly_installing-openjdk-8-on-red-hat-enterprise-linux_openjdk
Chapter 2. Installing Red Hat build of OpenJDK 8 on Red Hat Enterprise Linux | Installing and using Red Hat build of OpenJDK 8 for RHEL | Red Hat build of OpenJDK | 8 | Red Hat Documentation
If you need to switch from one major version to another major version, issue the following command in your command-line interface (CLI) and then following the onscreen prompts: ... You can install Red Hat build of OpenJDK Java Runtime Environment (JRE) using the system package manager, yum.
Find elsewhere
🌐
OpenJDK
openjdk.org › install
OpenJDK: Download and install
Oracle's OpenJDK JDK binaries for Windows, macOS, and Linux are available on release-specific pages of jdk.java.net as .tar.gz or .zip archives. As an example, the archives for JDK 13 may be found on jdk.java.net/13 and may be extracted on the command line using ... The openjdk-8-jre package contains just the Java Runtime Environment. If you want to develop Java programs then please install the openjdk-8-jdk package.
🌐
Oracle
java.com › es › download › linux_manual.jsp
Descargar software de Java para Linux
Esta descarga está destinada a usuarios finales que necesiten Java para ejecutar aplicaciones en equipos de escritorio o ordenadores portátiles. Java 8 se integra con su sistema operativo para ejecutar aplicaciones Java instaladas de forma independiente.
🌐
Liquid Web
liquidweb.com › home › help docs › server administration › linux server administration › how to install java on centos 7 (java 8)
How to Install Java on CentOS 7 (Java 8) | Liquid Web
December 15, 2025 - Learn how to install Java on CentOS 7 (Java 8). These instructions include updating the server, verifying the Java install, setting Java's home environment, as well as setting Java's path.
🌐
Medium
medium.com › appliedcode › how-to-install-java-8-jdk-8u45-on-ubuntu-linuxmint-via-ppa-1115d64ae325
How to Install JAVA 8 (JDK 8u45) on Ubuntu & LinuxMint Via PPA | by Mohit Sethi | Appliedcode | Medium
February 9, 2017 - This blog post will help you to Install Oracle JAVA 8 (JDK/JRE 8u25) on Ubuntu 14.04 LTS, 12.04 LTS and 10.04 and LinuxMint systems using PPA File.
🌐
LinuxBuz
linuxbuz.com › linuxhowto › install-java-8-ubuntu
How to Install Java 8 on Ubuntu 20.04 - LinuxBuz
April 2, 2026 - First, Log in and visit the Oracle Downloads page and locate your desired version of Java. In this case, we will install Java SE 11 LTS as shown below: Next, click on the JDK Download button.
🌐
ExtraVM
extravm.com › billing › knowledgebase › 17 › Install-Java-8-JDK-on-CentOS-or-AlmaLinux-or-Rocky-Linux-single-command.html
Install Java 8 JDK on CentOS / AlmaLinux / Rocky Linux (single command) - ExtraVM
UPDATE April 2022: If you are using a more recent OS version you cam install many OpenJDK versions via dnf/yum, such as Java 17, by running dnf install java-17-openjdk -y or can get direct rpm links to some rpm packages from the Pkgs.org website, just use their search feature. https://pkgs.org/download/java-1.8.0-openjdk
🌐
IBM
ibm.com › docs › en › qradar-common
Installing Java on RHEL or CentOS Linux - IBM Documentation
December 1, 2025 - Go to IBM Semeru Runtimes Downloads , and download the IBM Semeru Runtime Certified Edition JDK, Version 11 RPM package for Linux® on 64-bit systems. Copy the installation package to your computer or VM where you plan to install the Disconnected Log Collector, and then complete the remaining steps on that computer or VM. To install Java on your RHEL or CentOS machine, run the following command:
🌐
Medium
hirosht.medium.com › install-oracle-jdk-1-8-and-set-environment-variables-in-ubuntu-82443a7b789
Install Oracle JDK 1.8 and Set environment variables in Ubuntu | by Hirosh Tharaka | Medium
May 17, 2019 - Download the JavaSE Development Kit 8 from the given link below. URL : https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html (Linux x64 : jdk-8u211-...
🌐
Pearl Linux OS
linuxmadesimple.info › 2024 › 04 › how-to-install-java-8-on-chromebook.html
How to install Java 8 on a Chromebook
June 28, 2024 - If you haven't already enabled Linux apps on your Chromebook, follow these steps: ... sudo echo "deb https://deb.debian.org/debian sid main" | sudo tee /etc/apt/sources.list.d/chrome_os_made_simple_java8.list sudo apt update sudo apt install openjdk-8-jdk sudo rm /etc/apt/sources.list.d/chrome_os_made_simple_java8.list
🌐
Oracle
oracle.com › java › technologies › javase
Java Archive Downloads - Java SE 8 | Oracle Deutschland
Downloading these releases requires an oracle.com account. If you don't have an oracle.com account you can use the links on the top of this page to learn more about it and register for one for free. For current Java releases, please consult the Oracle Software Download page.
🌐
WiKID Systems
wikidsystems.com › support › faq › how-can-i-install-oracle-jdk-8-from-the-command-line
How can I install Oracle JDK 8 from the command line?
curl -v -j -k -L -H "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u51-b16/jdk-8u51-linux-x64.rpm > jdk-8u51-linux-x64.rpm ... At this point you should upgrade your WiKID rpms. (There's a bug in release 4.0.3-b1903 that over-writes the JCE policy with older ones.) If you need to upgrade or install WiKID, do so now.