Version 1 (modified by Fran Boon, 8 years ago) ( diff )


Installing Java for Debian 7 Wheezy

# Remove OpenJDK & dependent packages
apt-get remove openjdk-6-jre-lib
# Install a fake package to tell Debian that a valid Java is installed
dpkg -i oracle-java-pkg-for-debian_2.0.0+r20140717_all.deb
# Download Sun Java via Browser (need to accept T&C)
mkdir /usr/lib/jvm
cd /usr/lib/jvm
tar zxvf /tmp/server-jre-7u80-linux-x64.tar.gz
ln -s /usr/lib/jvm/jdk1.7.0_80 /usr/lib/jvm/java-sun
rm /usr/bin/java
ln -s /usr/lib/jvm/java-sun/bin/java /usr/bin/java
rm /usr/bin/javac
ln -s /usr/lib/jvm/java-sun/bin/javac /usr/bin/javac

vi /etc/profile.d/java
export JAVA_HOME
Note: See TracWiki for help on using the wiki.