Java21 Installation on RHEL
Was this helpful?
This article describes the steps required to install Java 21 (OpenJDK) on a Red Hat Enterprise Linux (RHEL) system. The procedure ensures that the required Java runtime is installed and verified for use with OvalEdge components.
The steps apply to RHEL 7, RHEL 8, and RHEL 9 environments with minor variations in package management commands.
Ensure the following before proceeding:
Access to a RHEL 7, RHEL 8, or RHEL 9 machine
Root or sudo privileges
Internet connectivity to download packages from repositories
Update System Packages
Run the appropriate command to update system packages:
For RHEL 8 and RHEL 9:
sudo dnf update -yFor RHEL 7:
sudo yum update -yInstall Java 21 (OpenJDK)
For RHEL 8 and RHEL 9:
sudo dnf install java-21-openjdk java-21-openjdk-devel -yFor RHEL 7:
sudo yum install java-21-openjdk-devel -yVerify Installation
Run the following command to verify the installation:
java -versionExpected output:
openjdk version "21.x.x"Sample Reference Screenshot:

Copyright © 2026, OvalEdge LLC, Peachtree Corners, GA, USA.
Was this helpful?
Was this helpful?

