LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-26-2010, 09:06 AM   #1
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 690

Rep: Reputation: 34
Java jre-6u22 not listed in alternatives


Hello,

I have the following in /usr/java :

[root@jonas java]# ls -l
total 40668
lrwxrwxrwx. 1 root root 16 2010-11-26 15:45 default -> /usr/java/latest
drwxr-xr-x. 7 root root 4096 2010-11-26 15:44 jre1.6.0_22
-rw-r--r--. 1 root root 20946625 2010-09-15 12:42 jre-6u22-linux-i586.rpm
-rwxr-xr-x. 1 root root 20691198 2010-11-26 16:00 jre-6u22-linux-i586-rpm.bin
lrwxrwxrwx. 1 root root 21 2010-11-26 15:45 latest -> /usr/java/jre1.6.0_22

But the jre-6u22 is not listed :

[root@jonas java]# /usr/sbin/alternatives --config java

There are 3 programs which provide 'java'.

Selection Command
-----------------------------------------------
+ 1 /usr/lib/jvm/jre-1.6.0-openjdk/bin/java
2 /usr/lib/jvm/jre-1.5.0-gcj/bin/java
* 3 /usr/java/default/bin/java

Enter to keep the current selection[+], or type selection number:


How can I run java jre-6u22 ??
 
Old 11-26-2010, 09:33 AM   #2
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Probably like this : (( LQ Search , Tag = alternatives ))

Setting up a new java : 1) su
2)
/usr/sbin/alternatives --install /usr/bin/java java /usr/java/jre1.6.0_22/bin/java 22

3) /usr/sbin/alternatives --config java

..
 
Old 11-26-2010, 09:43 AM   #3
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 690

Original Poster
Rep: Reputation: 34
I need to set a variable $JRE_HOME which points to the folder where Java is installed.

What directory is this then ?
 
Old 11-26-2010, 11:16 PM   #4
jay73
LQ Guru
 
Registered: Nov 2006
Location: Belgium
Distribution: Ubuntu 11.04, Debian testing
Posts: 5,019

Rep: Reputation: 133Reputation: 133
The directory that contains the "bin" subdirectory.

/usr/java/jre1.6.0_22
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Java Woes: A Java Runtime Environment (JRE) or Java Development Kit (JDK) must be available ... chytraeus Slackware 10 11-27-2010 10:04 AM
puzzle JRE,RedHat, and alternatives tool sgruver Red Hat 3 10-30-2007 01:22 PM
JAVA JRE installation to view java applet through browser dipenchaudhary Linux - Software 1 01-23-2006 09:20 AM
java jre luap Linux - Software 5 02-16-2003 11:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:34 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration