Now it is possible to install openjdk-11 this way:

sudo apt-get install openjdk-11-jdk

(Previously it installed openjdk-10, but not anymore)

Answer from user5479362 on Stack Overflow
🌐
TecAdmin
tecadmin.net › install-oracle-java-11-on-ubuntu-16-04-xenial
How To Install Oracle Java 11 on Ubuntu 16.04 LTS (Xenial) – TecAdmin
April 26, 2025 - You need to add the following PPA to your Ubuntu system. This PPA contains a package oracle-java11-installer having the Java installation script. ... Then install Java 11 using the script provided in these packages. This script downloads the Java archive from the official site and configures ...
Discussions

What is the point of all these new Java versions when Java 8 is all that seems to be supported by most apps?
Because they switched to a new release model which allows for them to get new features out faster. Same thing happened when Firefox and chrome switched to a timed release model. People bitched about version numbers but slowly got use to the fact that "I don't really care that this is firefox 82". From an organization standpoint, this has been great for the Java getting features out. It used to be that they'd say "Ok, we are going to target key feature X for java Y". The problem with that is nearly all project development got devoted to that feature and ultimately "when" java would go out was completely unknown. Further, releases where crazy times for JDK developers. With the new model, they've been able to work on a lot more features in parallel. A ton of usability features made it in (records, pattern matching, string literals) which never would have made it in the old model. Further, it's allowed them to slowly walk in huge features (Valhalla, loom, etc) making pre-emptive changes needed to support massive changes in the future. Post Java 9, the upgrades have been a breeze. Honestly, I almost wish they'd move to an even faster release model to really force people to stop caring so much about these version numbers. Rust does a release every 6 weeks and I think that works great. Nobody cares that it's now Rust 1.50 or whatever. More on reddit.com
🌐 r/java
45
0
April 19, 2021
Thinkorswim on Ubuntu
this was a little tricky but I have gotten it to work.First you want to get Java 8 installed.Once you install Java,then you need to choose the version cause itll make Java 11 default,once you change it to 8,then the installer runs just fine. Also remember to change the installer to be "executing"(right click,properties,check the box). I think with your case,you should just run this to change it to 8 because I ran into the same issue and once I switched it to 8,I had no problems. sudo update-java-alternatives -s java-8-oracle I should note I am using LTS 18.04 but it should work if youre on 18 or 19 More on reddit.com
🌐 r/thinkorswim
11
5
October 25, 2019
🌐
Ubuntu
ubuntu.com › tutorials › install-jre
Install the Java Runtime Environment | Ubuntu
(Alternatively, you may opt to use a specific Java version, using for example the openjdk-11-jre package; as updates are released for that version of the Java Virtual Machine, that packages will be updated, allowing you to stick to the latest and greatest update of one specific version of the Java language.)
🌐
Baeldung
baeldung.com › home › devops › installing java on ubuntu
Installing Java on Ubuntu | Baeldung
January 8, 2024 - Learn how to install OpenJDK and Oracle JDK versions 8 through 11 on Ubuntu systems.
🌐
GitHub
gist.github.com › samiujan › fddcc8e3d422dc72ba6231f43de4ff83
openjdk 11 installation on ubuntu 16 · GitHub
openjdk 11 installation on ubuntu 16 · This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters ·
🌐
TheServerSide
theserverside.com › blog › Coffee-Talk-Java-News-Stories-and-Opinions › How-do-I-install-Java-on-Ubuntu
How to install Java 21 on Ubuntu
using /usr/lib/jvm/java-11-openjdk-amd64/bin/jconsole Setting up default-jdk (2:1.21) ... To validate the successful install of Java on Ubuntu, and to ensure the JDK’s bin directory is accessible through the OS’s PATH variable, issue the following command:
Find elsewhere
🌐
DigitalOcean
digitalocean.com › community › tutorials › how-to-install-java-with-apt-on-ubuntu-22-04
How to Install Java with Apt on Ubuntu (JRE & JDK) | DigitalOcean
February 2, 2026 - You can install a specific version of Java on your Ubuntu system by using the apt command. For example, to install Java 11, you can run the following command:
🌐
Ubuntu Shell
ubuntushell.com › install-java-on-ubuntu
How to Install Java on Ubuntu: A Step-By-Step Guide
March 7, 2026 - Learn how to install Java on Ubuntu using package manager and the distribution package, as well as methods for managing multiple Java versions.
🌐
GitHub
gist.github.com › peteristhegreat › 4cc299a10c73a7eeb09594ad453b4b52
Installing Java 11 on ubuntu · GitHub
$ md5 jdk-11* MD5 (jdk-11.0.14_linux-x64_bin (1).tar.gz) = c2037b5f2e2a6ddcfbdfe1489bccfd63 MD5 (jdk-11.0.14_linux-x64_bin.tar.gz) = c2037b5f2e2a6ddcfbdfe1489bccfd63 · After all the things above, you can just use the download link from oracle in your script. Here's my working script. #!/usr/bin/env bash export DEBIAN_FRONTEND=noninteractive # set -x cache_folder=/var/cache/oracle-jdk11-installer-local/ sudo mkdir -p $cache_folder #url='https://download.oracle.com/otn/java/jdk/11.0.4+10/cf1bbcbf431a474eb9fc550051f4ee78/jdk-11.0.14_linux-x64_bin.tar.gz' #url='https://download.oracle.com/otn/jav
🌐
DigitalOcean
digitalocean.com › community › tutorials › how-to-install-java-with-apt-on-ubuntu-20-04
How To Install Java with Apt on Ubuntu | DigitalOcean
February 5, 2026 - OutputCommand 'java' not found, but can be installed with: sudo apt install default-jre # version 2:1.17-75, or sudo apt install openjdk-17-jre-headless # version 17.0.17+10-1~24.04 sudo apt install openjdk-21-jre-headless # version 21.0.9+10-1~24.04 sudo apt install openjdk-11-jre-headless # version 11.0.29+7-1ubuntu1~24.04 sudo apt install openjdk-25-jre-headless # version 25.0.1+8-1~24.04 sudo apt install openjdk-8-jre-headless # version 8u472-ga-1~24.04 sudo apt install openjdk-19-jre-headless # version 19.0.2+7-4 sudo apt install openjdk-20-jre-headless # version 20.0.2+9-1 sudo apt install openjdk-22-jre-headless # version 22~22ea-1
🌐
Mkyong
mkyong.com › home › java › how to install java jdk on ubuntu
How to install Java JDK on Ubuntu - Mkyong.com
March 29, 2021 - This tutorial shows you how to install OpenJDK 8, 11, and 16 on Ubuntu 20, apt install automatically, manual installation, switch different JDK versions, etc.
🌐
TutorialsPoint
tutorialspoint.com › how-to-install-java-with-apt-get-on-ubuntu-16-04
How to Install Java with Apt-Get on Ubuntu 16.04
Need to get 11.9 MB of archives. ..................................................................................... To install the oracle JDK, use the following command – ... Oracle Java (JDK) Installer (automatically downloads and installs Oracle JDK7 / JDK8 / JDK9). There are no actual Java files in this PPA. More info (and Ubuntu installation instructions): - for Oracle Java 7: <a href="http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html" rel="nofollow noopener noreferrer" target="_blank">http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.htm
🌐
PhoenixNAP
phoenixnap.com › home › kb › sysadmin › how to install java on ubuntu
How to Install Java on Ubuntu
February 20, 2025 - This step-by-step guide will show you how to install Java on Ubuntu.
🌐
MakeUseOf
makeuseof.com › home › linux › how to install java on ubuntu and remove it when you’re done
How to Install Java on Ubuntu and Remove It When You’re Done
February 23, 2023 - Need to install Java on your Ubuntu system? Whether you're coding in Java or using an app, here's how to get it running.
🌐
LinuxCapable
linuxcapable.com › home › ubuntu › how to install openjdk 11 on ubuntu 26.04, 24.04 and 22.04
How to Install OpenJDK 11 on Ubuntu 26.04, 24.04 and 22.04 - LinuxCapable
April 28, 2026 - The Ubuntu Universe and Multiverse guide explains the repository components in more detail, but OpenJDK 11 only needs Universe. ... Install the full Java 11 JDK on Ubuntu with sudo apt install openjdk-11-jdk -y when you need both the runtime ...
🌐
Alibaba Cloud Community
alibabacloud.com › blog › how-to-install-java-jre-or-jdk-on-ubuntu-16-04_595548
How to Install Java (JRE or JDK) on Ubuntu 16.04 - Alibaba Cloud Community
November 13, 2019 - In this article, we will introduce some methods of using commands to install Java (JRE or JDK) on Ubuntu 16.04.
🌐
IONOS
ionos.com › digital guide › server › configuration › install java on ubuntu
How to install Java on Ubuntu step by step - IONOS
October 31, 2022 - It’s well known that you can install Java on Windows 11 but adding it to a machine running Linux is just as easy. To install Java on Ubuntu all you need is the command sudo apt install default-jre.
🌐
LinuxBabe
linuxbabe.com › home › how to install oracle java 8 and openjdk 11 on ubuntu 22.04, 20.04
How To Install Oracle Java 8 and OpenJDK 11 on Ubuntu 18.04, 19.04
October 27, 2022 - Run the following command to install OpenJDK 11 on Ubuntu 22.04 and Ubuntu 20.04 from the default repository. ... This will also install the openjdk-11-jre package, which contains the Java runtime environment and is required to run Java programs.