PDA

View Full Version : Java Update



SlickBlack
10th August 2008, 05:39 PM
Im trying to update Java but am having a little trouble following these directions. http://www.java.com/en/download/help/5000010500.xml#rpm Once it says "For example, to install the software in the /usr/java/ directory, Type: cd /usr/java/" im not sure exactly what to enter.

Hlingler
10th August 2008, 05:44 PM
See if this is any better/clearer: http://www.mjmwired.net/resources/mjm-fedora-f9.html#java

V

SlickBlack
10th August 2008, 05:52 PM
Sorry but thats even more confusing. Is there something im missing from my original instructions.

Hlingler
10th August 2008, 06:07 PM
To the best of my knowledge and recollection, that particular instruction is spurious: you do not have to create nor be in any particularr folder when installing the SUN JAVA RPM - it will create the folder if necessary, and install all the stuff as needed there.

So, just open a terminal window and move to the folder where the SUN JAVA RPM is located, and "pull the trigger".

V

SlickBlack
10th August 2008, 06:16 PM
Not sure if I even have a file names SUN JAVA RPM. I tried searching for it with no results. So what your saying is if I happen to find this file and click it while the terminal is open, it will auto install it?

Hlingler
10th August 2008, 06:35 PM
Not sure if I even have a file names SUN JAVA RPM. I tried searching for it with no results. So what your saying is if I happen to find this file and click it while the terminal is open, it will auto install it?No, it won't "auto-install", and there's no file named "SUN JAVA RPM".

What I meant by "SUN JAVA RPM" is whatever file it is from that website that you're trying to update, which I assume from your post is some file called: jre-6u<version>-linux-i586-rpm.bin

So, you would download that jre-6u<version>-linux-i586-rpm.bin file, open a terminal, become root user (STEP 1 & 2), and move into the folder where you downloaded it (STEP 3) NOT the folder /usr/java (ignore that line, it's spurious), make it executable as per the instructions (STEP 4), then start the install (STEP 5), and so on....

V

SlickBlack
10th August 2008, 06:49 PM
Im just not sure how to type out the file that its in. Any ideas what it may look like?

Hlingler
10th August 2008, 07:02 PM
It should look like (be named) something very close to: jre-6u<version>-linux-i586-rpm.bin

I don't know where you put it either! If you did in fact download it already, but can't find it nor remember where you put it, try:
find /home -name *rpm.bin*

That should tell you where it got to.
~]$ find /home -name *rpm.bin*
[..]
/home/Shared/Linux_RPMs-generic/jre-6u4-linux-i586-rpm.bin
/home/Shared/Linux_RPMs-generic/jre-6u6-linux-i586-rpm.bin
/home/Shared/Linux_RPMs-generic/jre-6u3-linux-i586-rpm.bin
/home/Shared/Linux_RPMs-generic/jre-6u5-linux-i586-rpm.bin
/home/Shared/Linux_RPMs-generic/jre-6u10-beta-linux-i586-rpm.bin
/home/Shared/Linux_RPMs-generic/jdk-6u6-linux-i586-rpm.bin
/home/Shared/Linux_RPMs-generic/jre-6u7-linux-i586-rpm.bin
~]$I found a museum full of them. Apparently, I need to do some housecleaning....

V

SlickBlack
10th August 2008, 07:12 PM
I meant I dont know what to type exactly in the Terminal. I saved it into a folder called Download on my desktop and my user name is user. What do I type in the terminal?

Hlingler
10th August 2008, 07:18 PM
(1) To become root user, type: su -
(2) enter root password when prompted
(3) To change directory to the folder where the file is: cd /home/user/desktop
(4) Verify that the desired file actually exists in that folder: ls
(4) Proceed as per the instructions, STEP 4, with making the file executable, and follow the rest of the instructions from there on.

V

SlickBlack
10th August 2008, 07:22 PM
When I try step three I get a this message "bash: cd: /home/user/desktop: No such file or directory"

Hlingler
10th August 2008, 07:26 PM
Linux is case-sensitive in almost all contexts: the folder you listed in previous post is:
/home/user/Download

So no, folder "/home/user/desktop" probably does not exist, but "/home/user/Download" does....

V

OOPS! My bad: "Download", not "Desktop" or "desktop"

SlickBlack
10th August 2008, 07:32 PM
I get the same result when I change it to Download.

Hlingler
10th August 2008, 07:39 PM
So, either there is no folder "/home/user/Download", or the file was saved to some other location, or not saved at all.

Try to find the downloaded file using the 'find' command:
find / -name \*rpm.bin*

The back-slash prevents mis-interpretation of the first wild-card by BASH.

For the moment, ignore messages such as: "You don't have permission to access that folder..."

V

SlickBlack
10th August 2008, 07:56 PM
There is definatly a folder on my desktop named Download and in that folder (amoung other things) is something called "jre-6u7-linux-i586-rpm.bin"

Hlingler
10th August 2008, 08:01 PM
Then the PATH to the file is probably: /home/user/Desktop/Download

See Post #10, but use instead /home/user/Desktop/Download

V

SlickBlack
10th August 2008, 08:18 PM
So I type in "cd /home/user/Desktop/Download" and it comes up as [root@wrangler Download]#. I then type in 1s but it comes up as command not found.

Hlingler
10th August 2008, 08:21 PM
That's: 'ls' as in "list", not the number "1"

V

SlickBlack
10th August 2008, 08:26 PM
K I see everything in that file. How do I download Java from here?

Hlingler
10th August 2008, 08:32 PM
What do you mean? From Post #15, you already downloaded it:
There is definatly a folder on my desktop named Download and in that folder (amoung other things) is something called "jre-6u7-linux-i586-rpm.bin"So, now you are inside that folder, and you see that file on the file list (the output of 'ls'), correct?

So, proceed with the next STEP to install it....

V

SlickBlack
10th August 2008, 08:44 PM
Awesome, thanks for your patience. One other thing, Wine has been acting up on me lately, not running programs it used to. For example ive been using PokerStars on Wine for the past few weeks and now it wont connect. PokerStars support asked for my Wine log files but im not sure how to access them.

SlickBlack
10th August 2008, 08:47 PM
Another example is FrostWire (an mp3 downloader) which worked fine. Now when I try to open it, it tells me I need a later version of Java. Which with your help I just updated and then same message still pops up.

PabloTwo
10th August 2008, 09:19 PM
You have to make the newest java package you installed active as the default java to use.
Open a terminal and enter

alternatives --display java | grep /bin/java
and show the results (output) from that command. Whichever version is shown with "priority 20000", that is the current active version in use.

If you know the full install path to the new "jre1.6.0_07" version you just installed, you can do:

/path/to/jre1.6.0_07/bin/jcontrol
and use the graphical interface (Sun Java Control Panel) to set that version as the default version. If you do that as a regular user, it will only effect your regular user account. If you call that as root, you can set it as default system wide.

Hlingler
11th August 2008, 01:51 AM
Another example is FrostWire (an mp3 downloader) which worked fine. Now when I try to open it, it tells me I need a later version of Java. Which with your help I just updated and then same message still pops up.I don't know much about WINE, but there are some excellent How-Tos in the "Guides and How-Tos" forum here. Also, I know that there's an RPM of FrostWire available, 'cause I got it - but I can't remember where. Search the forums for "frostwire RPM", I'm sure you'll find a link.

Paul showed you how to set up the alternatives to use SUN's JAVA and java browser plugin instead of whatever else you used before - you already know where it's at - somewhere under: /usr/java/...

Hint: if you set up the alternatives to point to /usr/java/default/... , then it will always point to the right place, even if you update the JAVA RPM....

V

PabloTwo
11th August 2008, 02:50 PM
Well, actually, I didn't show how how to use 'alternatives' to use SUN's java, just how to use alterntives to check to see if the new install of SUN java was even registered into the system. To do that, if it was not registered at all yet, you would

alternatives --install java java /path/to/jre1.6.0_07/bin/java 20000
If it was already registered but not set as the default, you would

alternatives --config java
then follow the prompt. Of course, you need to specify the actual full path to the java binary in the examples above. It's easier to use the GUI 'jcontrol' (java control panel) provided by the SUN java package. To locate it, if you're not sure (and to locate where the whole package is installed for that matter) do

su
enter roots password
updatedb
locate jcontrol | grep /bin/
Wait for the updatedb command to finish before trying to enter the next command, it could take awhile. The output from the last command will show you exactly what you need to type at the command prompt to bring up the SUN java control panel. You can use that graphical interface to set SUN java as the default java instead of the command line alternatives method.

As for the broswer plugin, in your FF location bar, enter

about:plugins
and scroll down to see which version of java is the active browser plugin. If it's not your new SUN java, you'll need to change that. But one thing at a time.