Oracle Java Installation - Linux
#Login as a root user
sudo su -
##Change dir to /opt
cd /opt
yum install wget -y
wget -c --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.rpm
yum install jdk-8u131-linux-x64.rpm -y
java -version
Monday, September 27, 2021
Java Installation in Ubuntu Linux Server
By default, Ubuntu 18.04 includes OpenJDK version 11,which is an open-source variant of the JRE and JDK.
To install this version, first update the package index with below command.
#sudo apt update
Then execute below commands based on which version you want to install.
#apt install default-jre : For Defauly version.
#apt install openjdk-11-jre-headless : For Java 11
#apt install openjdk-8-jre-headless : For Java 8
Verify the Java installation with below command.
#java -version
To install the JDK, execute the following command, which will also install the JRE.
#sudo apt install default-jdk
Verify that the JDK is installed by checking the version of javac, the Java compiler using below command.
#javac -version
To Install the Open JDK 8, use the below command.
#sudo apt install openjdk-8-jdk
Tuesday, February 25, 2020
Java Installation - Linux
#Login as a root user sudo su - |
#Install JRE 1.8
yum install java-1.8.0-openjdk -y
java -version
#Install JDK 1.8
yum install java-1.8.0-openjdk-devel -y
javac -version
#Install JRE 11
yum install java-11-openjdk -y
java -version
#Install JDK 11
yum install java-11-openjdk-devel -y
javac -version
sudo su - | |||||||
Comments
Post a Comment