Install Oracle JAVA JDK in your LINUX

6:27 AM , , 0 Comments

Installing Oracle's JAVA JDK in your Linux takes a roundabout work if yours is not a Fedora based system. Here we are gonna see how we install Oracle JAVA JDK in your GNU LINUX.



For Ubuntu based Systems, click here
For Fedora based Systems, click here

Ubuntu based Systems :

Method 1 (Automatic Installation) :

In this method, we are going to use WebUPD8's PPA to install Oracle JAVA JDK in your Ubuntu. All you have to do is open the terminal and type the following :
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
Thats it. It will automatically download java JDK and install it for you.

Method 2 (Manual Installation) :

  1. Download the tar.gz package from here
  2. Extract the contents to Desktop. Now you'll have the folder named jdk1.x.x_xx.
  3. Rename it to java.
  4. Now open terminal and type gksu nautilus
  5. Now click on 'File System' in the left pane.
  6. Now go to 'home' -> 'your_username' -> 'Desktop'
  7. Right click on the extracted folder and select Copy
  8. Now click on 'File System'
  9. Go to 'usr' folder and Paste the 'java' folder
  10. Open the terminal and type the following :
  11. sudo -i
    cd /etc/
    gedit bash.bashrc
    
  12. 'bash.bashrc' file will be opened in gedit. Go to the end of the file and type the following lines :
  13. export PATH=${PATH}:/usr/java/bin
    export JAVA_HOME=/usr/java/bin/java
    
  14. Now open Terminal and type the following :
  15. javac
  16. If everything went correct, You will get something like this :
Back to top

Fedora Based Systems :

  1. Download the rpm file from here
  2. And install it by double clicking it.
  3. Thats it. Done
Back to top

If you know of any other methods, mention them in the comments. Others may find it useful.

A LINUX enthusiast and tech passionate guy. Love to watch Anime and play cricket. Got extra bit of care in myself, guess that's what people call selfishness :-P Google+