Forum Stats

  • 3,826,761 Users
  • 2,260,705 Discussions
  • 7,897,072 Comments

Discussions

Installing Java 8 SE on Debian - Linux

gdillen
gdillen Member Posts: 44
edited May 26, 2014 7:41AM in Java 8 Questions

What is the recommended way to install Java 8 SE on Debian (32-bit or 64-bit):

1) As explained on this page JDK Installation for Linux Platforms

Installation of the 32-bit JDK on Linux Platforms

This procedure installs the Java Development Kit (JDK) for 32-bit Linux, using an archive binary file (.tar.gz).

These instructions use the following file:

jdk-8uversion-linux-i586.tar.gz 
  1. Download the file.Before the file can be downloaded, you must accept the license agreement. The archive binary can be installed by anyone (not only root users), in any location that you can write to. However, only the root user can install the JDK into the system location.
  2. Change directory to the location where you would like the JDK to be installed, then move the .tar.gz archive binary to the current directory.
  3. Unpack the tarball and install the JDK.
    % tar zxvf jdk-8uversion-linux-i586.tar.gz 

    The Java Development Kit files are installed in a directory called jdk1.8.0_version in the current directory.

  4. Delete the .tar.gz file if you want to save disk space.

or

2) su -

echo "deb <a href="http://ppa.launchpad.net/webupd8team/java/ubuntu">http://ppa.launchpad.net/webupd8team/java/ubuntu</a> trusty main" | tee /etc/apt/sources.list.d/webupd8team-java.list

echo "deb-src <a href="http://ppa.launchpad.net/webupd8team/java/ubuntu">http://ppa.launchpad.net/webupd8team/java/ubuntu</a> trusty main" | tee -a /etc/apt/sources.list.d/webupd8team-java.list

apt-key adv --keyserver <a href="http://keyserver.ubuntu.com/">keyserver.ubuntu.com</a> --recv-keys EEA14886 apt-get update

apt-get

install oracle-java8-installer

exit

Thanks.

Answers

  • Markus KARG
    Markus KARG Member Posts: 99

    The recommended way to install Java 8 on Debian is apt-get install openjdk-8-jre, but you'll have to wait until that package actually exists, which is not the case yet. Neither of the above ways you mention are recommended on Debian, but both should be working.