Installing Java and Flash (Debian/Ubuntu)

Installation instructions for Sun’s Java 6 and Adobe’s Flash.


For Debian prior to Wheezy, you will need to add the non-free repository to your /etc/apt/sources.list. Here is the corresponding line in mine :

deb squeeze main contrib non-free
deb-src squeeze main contrib non-free

Then update your system and install java :

$ apt-get update 
$ apt-get install sun-java6-jre sun-java6-plugin 
$ update-alternatives --config java 

Note : sun-java6-plugin is a plugin for your browser.

For Ubuntu, use the following script for creating a local apt repository.

For Debian Wheezy or others, you can no longer install Sun’s Java from the repositories. The easiest way is to download the JRE from the official site.

Extract it :

$ mkdir /usr/local/java
$ tar xvzf jre-7u25-linux-i586.tar.gz -C /usr/local/java/

Create a symlink for Firefox :

$ cd ~/.mozilla/plugins
$ ln -s /usr/local/java/jre1.7.0_25/lib/i386/

And, you’re done !


For Flash, you just need to grab the installation archive from the official site. Then extract it to /usr/. Finally, copy in ~/.mozilla/plugins. This should work for iceweasel/firefox.