Pages

Saturday, July 13, 2013

Upgrade Java Runtime (JRE) on Debin/Ubuntu

Its high time you upgrade your JRE on your linux, as any version before Java 7 update 11 has serious security flaws. 

Firefox, by default blocks java based on the version you have installed. It means it doesn't allow you to run any java application using these security-issue-ridden java versions.

But, not the same with other browsers or your OS. You got to update it immediately.

NOTE: openjdk jre is also similar to oracle java, hence you can expect same issues with open jdk too. Until you get an update on openjdk, I suggest you use oracle java, well it is not too complex to install oracle java as it looks like on the surface.

Here is how to be done: (OS: Ubuntu)


  1. Download latest java from oracle site http://www.oracle.com/technetwork/java/javase/downloads/jre7-downloads-1880261.html
  2. if you are using 32 bit linux(most likely intel, x86 arch), choose the right file to download(rpm type for redhat based, .gz for debian based)
  3. untar using command 'sudo tar -xzvf jre-7u25-linux-x64.tar.gz -C /usr/java/
  4. To enable this java on Firefox, create soft link for a lib libnpjp2.so from your java directory to firefox plugin directory. It looks something like this:                                                                 "sudo ln -s /usr/java/jre1.7.0_25/lib/amd64/libnpjp2.so /usr/lib/firefox/plugins/"
  5. to verfiy, restart firefox, go to "about:plugins" in address bar,  see if you have following information: "

    Java Plug-in 1.7.0_25

    File: libnpjp2.so
    Path: /usr/java/jre1.7.0_25/lib/amd64/libnpjp2.so "

    that's it, you are upgraded!

    For google-chrome, you don't have to do anything if you have untarred the jre under /usr/java. To verify, restart your chrome, go to 

    chrome://plugins/

    Look for 

    Java(TM) Download Critical Security Update
    Java plug-in for NPAPI-based browsers.
    Name:Java Plug-in 1.7.0_25
    Description:Java plug-in for NPAPI-based browsers.
    Version:
    Location:/usr/java/jre1.7.0_25/lib/amd64/libnpjp2.so

    (don't forget to remove older versions of java)

No comments:

Post a Comment