0

In the official website for download I can see two links for JDK for Linux.

Which one should I choose on my Ubuntu 12.04 ?

http://javadl.sun.com/webapps/download/AutoDL?BundleId=78694

or

http://javadl.sun.com/webapps/download/AutoDL?BundleId=78695

Varun
  • 1,969
  • 5
  • 18
  • 16

2 Answers2

2

The .rpm file is not for Ubuntu, but for Fedora, CentOS, and other distros based on Fedora.

You'd want to download the .tar.gz file. To install Java in Ubuntu 12.04, just press Ctrl+Alt+T on your keyboard to open Terminal. When it opens, run the command(s) below:

sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer

And after the installation finishes, if you wish to see if it was successful, you can run the following command:

java -version

Or if you want to download the file , then see How to install a .tar.gz (or .tar.bz2) file

Source:WebUpd8

Mitch
  • 107,631
1

Simplest method to install any application (including jdk) is to use the software centre or the add/remove programs..just search for jdk in the software centre.

abchk1234
  • 1,819
  • 1
  • 16
  • 24
  • I agree with Aditya. I've been manually installing and using Oracle's (Sun's) JDK in Ubuntu for years, but OpenJDK is good enough now, that I don't bother with the manual install anymore. Just install OpenJDK from the software center, and it will do all the messy setup and configuration for you. (You don't have to mess with external PPAs either). – Enterprise Aug 11 '13 at 17:35