Install OpenJDK17 on RHEL8

This article will show you how to install JDK17 on RHEL8 Server

Run install command

sudo dnf install java-17-openjdk

# Example output
  java-17-openjdk-1:                                                     java-17-openjdk-headless-1:                                                    

Verify installed java SDKs

java -version
# Example output
openjdk version "11.0.18" 2023-01-17 LTS
OpenJDK Runtime Environment (Red_Hat- (build 11.0.18+10-LTS)
OpenJDK 64-Bit Server VM (Red_Hat- (build 11.0.18+10-LTS, mixed mode, sharing)

# List installed jdk
sudo dnf list installed "java*"

# Example output:
java-11-openjdk.x86_64                                                               1:                                                                @rhel-8-for-x86_64-appstream-rpms
java-11-openjdk-devel.x86_64                                                         1:                                                                @rhel-8-for-x86_64-appstream-rpms
java-11-openjdk-headless.x86_64                                                      1:                                                                @rhel-8-for-x86_64-appstream-rpms
java-17-openjdk.x86_64                                                               1:                                                                 @rhel-8-for-x86_64-appstream-rpms
java-17-openjdk-headless.x86_64                                                      1:                                                                 @rhel-8-for-x86_64-appstream-rpms
javapackages-filesystem.noarch                                                       5.3.0-1.module+el8+2447+6f56d9a6                                                      @rhel-8-for-x86_64-appstream-rpms
Scroll to Top