Java is already installed on some Linux distros by default, but usually just the JRE is installed and not the JDK.
To verify if Java is installed, the 'java' command can be checked, and if JDK isn't installed, the 'javac' command won't be found.
Fedora stores JREs/JDKs within /usr/lib/jvm. Look into its contents or query the available Java version installed in your system.
To install OpenJDK, you can use Fedora's package manager 'dnf'. Use 'dnf search jdk' to get a list of available Java versions and package variants.
To install the full JDK with all the necessary tools for Java development, you need the development variant of the package. It usually contains the '-devel' term suffix in the name for dnf.
Oracle JDK can be installed by visiting the official Oracle SE Downloads page and downloading the appropriate package for your platform. It can be installed by double-clicking on the downloaded file and selecting Install.
It is possible to work with multiple Java installations on Linux, and the 'update-alternatives' command manages the symbolic links comprising the alternatives system.
To switch among available alternatives of a command, use 'sudo update-alternatives --config' followed by the command name.
The 'JAVA_HOME' environment variable can be set to the JDK folder path, and the binaries within 'JAVA_HOME' like 'java' and 'javac' can be added to PATH.
Manually setting the configuration through your shell profile should not be needed if you use the update-alternatives method to manage Java installations.