Solved

Java versions on Linux

Posted on 2014-10-13
4
315 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 38

Expert Comment

by:Gerwin Jansen, EE MVE
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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…

679 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