Solved

Java versions on Linux

Posted on 2014-10-13
4
311 Views
Last Modified: 2014-10-14
I have a RHEL 6.5 machine, and I typed in the java versions as follows

java -version
java version "1.7.0_65"
OpenJDK Runtime Environment (rhel-2.5.1.2.el6_5-x86_64 u65-b17)
OpenJDK 64-Bit Server VM (build 24.65-b04, mixed mode)

Open in new window


So I have a 64 bit Java on a 64 bit Linux

My question is, could there be any other java versions out there currently installed

If so, how do I discover which other versions are installed

Thanks
0
Comment
Question by:Anthony Lucia
4 Comments
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 250 total points
ID: 40378418
Check the subdirectories of /usr/lib/jvm.

Additionally, run: rpm -qa | grep -i java

With /usr/sbin/alternatives --display java

you'll see all the links to the currently active version and what other alternatives are available.
0
 
LVL 37

Expert Comment

by:Gerwin Jansen
ID: 40378580
As a last resort you can search the file system:

# find / -type f -name java 2>/dev/null | xargs file | grep -v ASCII
0
 
LVL 13

Assisted Solution

by:Sandy
Sandy earned 250 total points
ID: 40379882
/usr/sbin/alternatives --display java

and in case you found multiple instances then you can choose anyone by using below

 /usr/sbin/alternatives --config java


TY/SA
0
 

Author Closing Comment

by:Anthony Lucia
ID: 40379987
The best answers were

rpm -qa | grep -i java

and

/usr/sbin/alternatives --config java
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
configure dependency in POM for new database 3 25
awk sed 8 40
Linux server had an unexpected freeze. How to find out cause (sys logs)? 13 35
number in printf 13 27
Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
Fine Tune your automatic Updates for Ubuntu / Debian
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question