LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
LinkBack Search this Thread
Old 01-09-2011, 07:23 PM   #1
jonnie
LQ Newbie
 
Registered: Jan 2011
Posts: 15

Rep: Reputation: 0
Question install sun jdk for freenet


Hello,
I wanted to try freenet but it says it doesn't like the openjdk java which is by default installed with fedora.
I should get the sun jdk instead. How can I install that?
After browsing a while I downloaded a self-extracting jdk-6u23-linux-i586-rpm.bin file, which extracted + installed some rpm's. But freenet still says it's using openjdk.
- How can I see which java versions are installed on my fedora? (possibly multiple)
- How can I see which jvm is the default one? (should be still openjdk in my case)
- How can I change the default jvm so it uses the one I just installed?
Cheers & Thanks in advance
 
Old 01-10-2011, 04:16 AM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2013.07, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,199

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
Setting up a new java :

1) su
2)
/usr/sbin/alternatives --install /usr/bin/java java /usr/java/jdk1.6.0_23/bin/java 2

3) /usr/sbin/alternatives --config java
.. and then select the "sun" version.
4) exit

The command for version check : java -version
.. Should reply : java version "1.6.0_23"
Java(TM) SE Runtime Environment (build 1.6.0_23...
..
 
Old 01-10-2011, 01:20 PM   #3
jonnie
LQ Newbie
 
Registered: Jan 2011
Posts: 15

Original Poster
Rep: Reputation: 0
Lightbulb

Perfect, thanks!
Working great, freenet doesn't complain any more at all.

Seems this "alternatives" works like a version switch for arbitrary programs...
One more question, though. "alternatives" also had a lot of so-called slave-links installed for the openjdk version. However, it did't register any for my added sun version. Should I worry about that? Can it be that some things don't work properly because these links are missing?

Here's the output of alternatives --display java. Never mind the language (it's Swedish) but you can see the impressing list of null-values for my sun-java anyway:
Code:
java - statusen är automatisk.
 länk pekar för tillfället på /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
/usr/lib/jvm/jre-1.6.0-openjdk/bin/java - prioritet 16000
 slav javaws: /usr/lib/jvm/jre-1.6.0-openjdk/bin/javaws
 slav keytool: /usr/lib/jvm/jre-1.6.0-openjdk/bin/keytool
 slav orbd: /usr/lib/jvm/jre-1.6.0-openjdk/bin/orbd
 slav pack200: /usr/lib/jvm/jre-1.6.0-openjdk/bin/pack200
 slav rmid: /usr/lib/jvm/jre-1.6.0-openjdk/bin/rmid
 slav rmiregistry: /usr/lib/jvm/jre-1.6.0-openjdk/bin/rmiregistry
 slav servertool: /usr/lib/jvm/jre-1.6.0-openjdk/bin/servertool
 slav tnameserv: /usr/lib/jvm/jre-1.6.0-openjdk/bin/tnameserv
 slav unpack200: /usr/lib/jvm/jre-1.6.0-openjdk/bin/unpack200
 slav jre_exports: /usr/lib/jvm-exports/jre-1.6.0-openjdk
 slav jre: /usr/lib/jvm/jre-1.6.0-openjdk
 slav java.1.gz: /usr/share/man/man1/java-java-1.6.0-openjdk.1.gz
 slav javaws.1.gz: /usr/share/man/man1/javaws-java-1.6.0-openjdk.1.gz
 slav keytool.1.gz: /usr/share/man/man1/keytool-java-1.6.0-openjdk.1.gz
 slav orbd.1.gz: /usr/share/man/man1/orbd-java-1.6.0-openjdk.1.gz
 slav pack200.1.gz: /usr/share/man/man1/pack200-java-1.6.0-openjdk.1.gz
 slav rmid.1.gz: /usr/share/man/man1/rmid-java-1.6.0-openjdk.1.gz
 slav rmiregistry.1.gz: /usr/share/man/man1/rmiregistry-java-1.6.0-openjdk.1.gz
 slav servertool.1.gz: /usr/share/man/man1/servertool-java-1.6.0-openjdk.1.gz
 slav tnameserv.1.gz: /usr/share/man/man1/tnameserv-java-1.6.0-openjdk.1.gz
 slav unpack200.1.gz: /usr/share/man/man1/unpack200-java-1.6.0-openjdk.1.gz
/usr/lib/jvm/jre-1.5.0-gcj/bin/java - prioritet 1500
 slav javaws: (null)
 slav keytool: /usr/lib/jvm/jre-1.5.0-gcj/bin/keytool
 slav orbd: (null)
 slav pack200: (null)
 slav rmid: (null)
 slav rmiregistry: /usr/lib/jvm/jre-1.5.0-gcj/bin/rmiregistry
 slav servertool: (null)
 slav tnameserv: (null)
 slav unpack200: (null)
 slav jre_exports: /usr/lib/jvm-exports/jre-1.5.0-gcj
 slav jre: /usr/lib/jvm/jre-1.5.0-gcj
 slav java.1.gz: (null)
 slav javaws.1.gz: (null)
 slav keytool.1.gz: (null)
 slav orbd.1.gz: (null)
 slav pack200.1.gz: (null)
 slav rmid.1.gz: (null)
 slav rmiregistry.1.gz: (null)
 slav servertool.1.gz: (null)
 slav tnameserv.1.gz: (null)
 slav unpack200.1.gz: (null)
/usr/java/jdk1.6.0_23/bin/java - prioritet 2
 slav javaws: (null)
 slav keytool: (null)
 slav orbd: (null)
 slav pack200: (null)
 slav rmid: (null)
 slav rmiregistry: (null)
 slav servertool: (null)
 slav tnameserv: (null)
 slav unpack200: (null)
 slav jre_exports: (null)
 slav jre: (null)
 slav java.1.gz: (null)
 slav javaws.1.gz: (null)
 slav keytool.1.gz: (null)
 slav orbd.1.gz: (null)
 slav pack200.1.gz: (null)
 slav rmid.1.gz: (null)
 slav rmiregistry.1.gz: (null)
 slav servertool.1.gz: (null)
 slav tnameserv.1.gz: (null)
 slav unpack200.1.gz: (null)
Den för tillfället "bästa" versionen är /usr/lib/jvm/jre-1.6.0-openjdk/bin/java.
 
Old 01-10-2011, 01:56 PM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2013.07, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,199

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
Quote:
Never mind the language (it's Swedish)
Everybody understand Swedish, don't they ? ..

Quote:
Can it be that some things don't work properly because these links are missing ?
If 'java -version' and 'javac -version' show the right answer :
Nothing to worry about.

..
 
  


Reply

Tags
java


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Sun Jdk vs Eclipse Alexvader Slackware 15 10-24-2009 02:09 PM
I can't install sun-java6-jdk sun-java6-bin sun-java6-jre citye Linux - Newbie 2 10-18-2009 04:54 AM
LXer: How To Install Sun Java SE 6 JDK and NetBeans 5.5.1 - Fedora 7 LXer Syndicated Linux News 0 08-22-2007 06:51 PM
Installing Sun JDK naiveguy Linux - General 2 04-17-2006 02:15 PM
installing Sun JDK in FC5 fakie_flip Linux - Software 1 04-14-2006 05:28 PM


All times are GMT -5. The time now is 01:25 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration