We can still download the JDK and install it on Ubuntu manually.Ģ.2 Extracts the downloaded JDK to /opt/jdk-16. If we want the latest Java JDK, for example JDK 16, early-access builds, or other JDK builds like AdoptOpenJDK, which are not available in the Ubuntu default repository. OpenJDK 64-Bit Server VM (build 25.282-b08, mixed mode) 2. java-1.8.0-openjdk-amd64.jinfoĤ drwxr-xr-x 7 root root 4096 Mac 29 15:06 java-8-openjdk-amd64Ĥ drwxr-xr-x 3 root root 4096 Feb 18 13:53 openjdk-11ġ.5 And the global /usr/bin/java is linked to one of the installed JDK.Ġ lrwxrwxrwx 1 root root 22 /usr/bin/java -> /etc/alternatives/javaĠ lrwxrwxrwx 1 root root 46 Mac 29 15:15 /etc/alternatives/java -> /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/javaġ.6 We can use java -version to verify if Java JDK is installed correctly. The apt install the Java JDK at this path /usr/lib/jvm.Ĥ drwxr-xr-x 5 root root 4096 Mac 29 15:06. Terminal $ sudo apt install openjdk-11-jdk Terminal $ sudo apt install openjdk-8-jdk The below search result show four OpenJDK are available to install. This example shows how to use apt install to install the OpenJDK 8 and 11 on Ubuntu.ġ.1 We can use sudo apt search openjdk to find all available OpenJDK in the default repository. This tutorial shows you how to install OpenJDK 8, 11, 16, and other JDK builds on Ubuntu 20.
0 Comments
Leave a Reply. |