Custom Search

Tuesday, April 30, 2019

How to install Java on Ubuntu 19.04 18.04

How to install Java on Ubuntu

sudo add-apt-repository ppa:linuxuprising/java

sudo apt update

sudo apt install oracle-java12-installer

java -version

sudo update-alternatives --config java

sudo vim /etc/environment
JAVA_HOME=/usr/lib/jvm/java-12-oracle

source /etc/environment

echo $JAVA_HOME

No comments:

Post a Comment