Results 1 to 10 of 10

Thread: upgrading / reinstalling java

  1. #1
    Join Date
    Oct 2010
    Location
    China
    Beans
    159
    Distro
    Ubuntu Gnome 14.04 Trusty Tahr

    upgrading / reinstalling java

    I'm looking to remove my current version of Java and upgrade to the newest versions of Java and hopefully any other components like flash etc, can anyone advise the best way to go about doing this?

    In my system > preferences I have sun Java and OpenJDK listed so I',m not even sure what kind of Java I am running right now =/
    Yes, I am a criminal. My crime is that of curiosity. My crime is that of judging people by what they say and think, not what they look like. My crime is that of outsmarting you, something that you will never forgive me for

  2. #2
    Join Date
    May 2009
    Location
    Canada
    Beans
    868
    Distro
    Ubuntu Development Release

    Re: upgrading / reinstalling java

    Just open the software center or synaptic package manager (from System > Administration) and just search for flash and java (and whatever else) and remove it.
    Intel Core i7 970 6/12 (Cores/Threads) 3.2GHz 12MB Cache
    6GB DDR3
    1866MHz RAM | ATI Radeon HD 5770 1GB GDDR5
    60GB SSD
    (/) | 1TB 64MB Cache HDD (/home)
    Ubuntu Oneiric
    Ocelot 11.10 x64

  3. #3
    Join Date
    Dec 2010
    Location
    South Carolina
    Beans
    25
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: upgrading / reinstalling java

    I removed all Java via Packet Manager and followed this thread/post:http://ubuntuforums.org/showpost.php...71&postcount=9

    Works great for me.
    "If your outgo is greater than your income,then your upkeep will be your downfall".-Lucious Hutchinson (RIP)

  4. #4
    Join Date
    Oct 2010
    Location
    China
    Beans
    159
    Distro
    Ubuntu Gnome 14.04 Trusty Tahr

    Re: upgrading / reinstalling java

    Unfortunately I can't visit any google sites as I am living in China, though none of the .bin files from Java.com seem to be relevant to my version of Ubuntu 10.04.

    I have been looking around the Package Manager but there is so much stuff on there I don't know where to start, it says I have Sun Java 6 installed but I'm guessing its out of date as Java.com says I need to upgrade and I can't play Minecraft
    Yes, I am a criminal. My crime is that of curiosity. My crime is that of judging people by what they say and think, not what they look like. My crime is that of outsmarting you, something that you will never forgive me for

  5. #5
    Join Date
    Dec 2010
    Location
    South Carolina
    Beans
    25
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: upgrading / reinstalling java

    I used the Linux self extracting file from Java website which is a .bin file.(jre6u23-linux-i586.bin).

    Direct link for X32 bit version:http://javadl.sun.com/webapps/downlo...BundleId=43871

    Here are the instructions that worked for me,please follow exactly:

    HOW-TO FOR 32 BIT UBUNTU


    Remove the old version

    First you'll want to remove the old JRE or openJDK (if you have it).

    When JRE is installed from the repositories, do it like this:

    System - Administration - Synaptic Package Manager

    Query: sun java

    Tick all installed packages and choose complete removal.

    When it's installed manually in /opt/java, see the instruction at the bottom of this column (under the header Removal).

    If you don't have JRE, then you'll probably have openJDK. That one should be completely removed as well. That can also be done with Synaptic Package Manager (query: openjdk).



    Get JRE

    Get the right file from the Java website: http://www.java.com

    For 32 bit you want Linux (self-extracting file); the name of this file ends on i586.bin. You don't want Linux RPM (self extracting file), of which the file name ends on i586-rpm.bin, because RPM is not built for Ubuntu, but for other Linux distro's.

    Note: Store the file in the folder Downloads. So in /home/YourUserName/Downloads. Firefox puts downloaded files there by default, but not all web browsers do it like that.

    For example: user John should place the file in /home/John/Downloads. When in doubt, check it: upper panel of your desktop - Places - Downloads.

    This is important for the terminal commands that you'll execute later on, because otherwise they won't be correct.



    Install JRE (32-bit)

    Note: the terminal commands in this how-to possibly refer to an older version of JRE. When there's a newer version, you can simply adapt the file names in the terminal commands.

    This how-to has been written for JRE 6 update 23 (32 bit version).


    1. Go to the folder opt, with the following command:

    Applications - Accessories - Terminal

    Type (use copy/paste: rapidly click three times on the blue line, in order to select the entire line).
    cd /opt

    Press Enter.


    2. Create a new subfolder, with the following command line.
    Type (copy/paste):
    sudo mkdir java

    Press Enter.

    Type your password. You won't see anything, not even dots, this is normal.
    Press Enter.


    3. Go to the new folder, with the following command.
    Type (copy/paste):
    cd java

    Press Enter.


    4. Create a new subfolder, with the following command.
    Type (copy/paste):
    sudo mkdir 32

    Press Enter.


    5. Move the JRE file that you just downloaded, into this newest folder, with the following command.
    Type (copy/paste):
    sudo mv ~/Downloads/jre-6u23-linux-i586.bin /opt/java/32

    Press Enter.


    6. Make the file executable, with the following command.
    Type (copy/paste):
    sudo chmod 755 /opt/java/32/jre-6u23-linux-i586.bin

    Press Enter.

    Now you're going to install JRE, by executing this file.


    7. First, go to the new folder, with the following command.
    Type (copy/paste):
    cd /opt/java/32

    Press Enter.


    8. Execute the file, with the following command.
    Type (copy/paste):
    sudo ./jre-6u23-linux-i586.bin

    Press Enter.

    Now the license agreement appears.
    Press as many times on the space bar, until you see the following text:
    Do you agree to the above license terms? [yes or no]

    Type:
    yes

    Press Enter.

    Note: it's possible that you won't see a license agreement. For example because you've already accepted it previously, during the installation of an older version of JRE from the repositories.



    Inform the system and make the new JRE the default

    9. Now you'll want to tell the system, that there's a new Java version available.

    Type (copy/paste):
    sudo update-alternatives --install "/usr/bin/java" "java" "/opt/java/32/jre1.6.0_23/bin/java" 1

    Press Enter.

    Note: are you updating from a previous Java version, which you have removed manually? Then you'll need to execute the above command twice, because you'll get an error message the first time.


    10. Tell the system, that the new Java must be the default:

    Type (copy/paste):
    sudo update-alternatives --set java /opt/java/32/jre1.6.0_23/bin/java

    Press Enter.



    Install the Firefox plugin

    11. Installing the Firefox plugin is simple. First execute the following command, in order to create a certain folder (if it doesn't exist already).

    Type in the terminal (copy/paste):
    mkdir ~/.mozilla/plugins

    Press Enter.

    If it exists already, you'll see a notification of that.


    12. Now remove the IcedTea plugin, if it has been installed.

    Type (copy/paste):
    sudo apt-get remove icedtea6-plugin

    Press Enter.


    13. Remove a former version of the Java plugin (may or may not be present, run the command just to make sure).

    Type (copy/paste):

    rm ~/.mozilla/plugins/libnpjp2.so

    Press Enter.


    14. Now you can install the plugin, by creating a symbolic link (you tell Firefox, where the plugin is located).

    Type (copy/paste):
    ln -s /opt/java/32/jre1.6.0_23/lib/i386/libnpjp2.so ~/.mozilla/plugins/

    Press Enter.



    Final check

    Now close and restart Firefox. Check if everything has succeeded. Type in the url bar of Firefox (not in the terminal!):

    about:plugins

    Press Enter.

    And scroll down, until you see something approximately similar to this:
    Java(TM) Plug-in 1.6.0_23

    You can also use this website:
    http://java.com/en/download/installed.jsp



    Other user accounts: repeat three commands

    Are there any other user accounts on the computer? Then repeat the following three commands in each user account:

    rm ~/.mozilla/plugins/libnpjp2.so

    and then (in case the plugins folder doesn't exist yet):

    mkdir ~/.mozilla/plugins

    and then:

    ln -s /opt/java/32/jre1.6.0_23/lib/i386/libnpjp2.so ~/.mozilla/plugins/



    Sun Java 6 Plugin Control Panel

    You can call up the Control Panel as follows (in each user account):

    Type (copy/paste):
    /opt/java/32/jre1.6.0_23/bin/ControlPanel

    Press Enter.

    Note: this command is only for JRE update 23. You'll need to adapt it when you use another version.



    Removal

    Do you wish to remove JRE again? It's very easy, to remove a manually installed JRE. As follows:

    Close Firefox (otherwise the java plugin will be in use).

    Now open file manager Nautilus with root rights, using the following terminal command.

    Applications - Accessories - Terminal

    Type (copy/paste):
    gksudo nautilus

    Press Enter.

    File system - opt

    Click on the folder java and delete it.

    Then remove the Java plugin:

    Type in the terminal (copy/paste):

    rm ~/.mozilla/plugins/libnpjp2.so

    Press Enter.
    Last edited by bludgard; December 31st, 2010 at 08:45 PM. Reason: Replaced smiley face with (:p) on about:plugins
    "If your outgo is greater than your income,then your upkeep will be your downfall".-Lucious Hutchinson (RIP)

  6. #6
    Join Date
    Oct 2010
    Location
    China
    Beans
    159
    Distro
    Ubuntu Gnome 14.04 Trusty Tahr

    Re: upgrading / reinstalling java

    Bludgard that installation worked perfectly, no problems at all.

    I'm updated and feel clean again, thanks so much for your time and help
    Yes, I am a criminal. My crime is that of curiosity. My crime is that of judging people by what they say and think, not what they look like. My crime is that of outsmarting you, something that you will never forgive me for

  7. #7
    Join Date
    Dec 2010
    Location
    South Carolina
    Beans
    25
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: upgrading / reinstalling java

    Glad I could contribute.

    Happy gaming,Legeril.

    One
    "If your outgo is greater than your income,then your upkeep will be your downfall".-Lucious Hutchinson (RIP)

  8. #8
    Join Date
    Oct 2007
    Location
    Manhattan, KS
    Beans
    80

    Re: upgrading / reinstalling java

    bludgard - you're a godsend! I've been fighting this thing for two days so my wife can play her Pogo.com games and quit driving me nuts! Worked like a charm!

    Wife =

    ~Maxx =

    All the best to ya!
    "Heavy rotation never made my world go 'round.
    Commercialization of music is what brought it down.
    "

    ~Prince

  9. #9
    Join Date
    Dec 2010
    Location
    South Carolina
    Beans
    25
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Wink Re: upgrading / reinstalling java

    Yeah.My wife loves her POGO,too!She prefers Windows/IE8 for that is what she is used to and there aren't the flash or Java issues.

    However,my OCD wouldn't let me rest until I had it nailed in Ubuntu/Firefox as well.

    Took me a few days and a lot of frustration to find the answer.

    Thanks to oldos2er,another forum member,for providing such a useful post.=D>

    Someone should really contact Java and let them know that their "Instructions" for install are a little too cryptic for the average user like me to understand.

    That being said,you are welcome.

    One
    "If your outgo is greater than your income,then your upkeep will be your downfall".-Lucious Hutchinson (RIP)

  10. #10
    Join Date
    Dec 2010
    Location
    South Carolina
    Beans
    25
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: upgrading / reinstalling java

    What happened to the other links provided by another poster?

    Something about .deb files?

    Just curious.Or am I in the wrong thread?

    One
    "If your outgo is greater than your income,then your upkeep will be your downfall".-Lucious Hutchinson (RIP)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •