How To Install Oracle Java 7 & 8 on Ubuntu 14.04 LTS

Oracle JDK

sudo apt-get install python-software-properties
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update


sudo apt-get install oracle-java7-installer


sudo apt-get install oracle-java8-installer

Java version to use as default

sudo update-alternatives –config java
sudo update-alternatives –config javac

Environment variable

sudo nano /etc/environment
source /etc/environment (reload the file)

, , , , ,

2 thoughts on “How To Install Oracle Java 7 & 8 on Ubuntu 14.04 LTS

  1. how it is possible that my terminal and my Ubuntu14 always respondes
    "Oracle JDK 7 is NOT installed."
    When I use either : sudo apt-get install oracle-java7-installer
    or sudo apt-get install oracle-java8-installer

    terminal says the SAME thing –

    download failed
    Oracle JDK 7 is NOT installed.

    That is crazy.

    I am starting to keep a serious gfrudge towards f** 14 version of Ubuntu. with version 13 I barely have had any problem….

Leave a Reply

Your email address will not be published. Required fields are marked *