Home » Oracle » How to check the java version in Unix & Windows

How to check the java version in Unix & Windows

Java is a high-level, class-based, object-oriented programming language that is designed to have as few implementation dependencies as possible. It was developed by Sun Microsystems (now owned by Oracle Corporation) and released in 1995. Java applications are typically compiled to bytecode that can run on any Java Virtual Machine (JVM), regardless of the underlying computer architecture

To check the Java version in Linux:

java -version
java version "1.8.0.107"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.8.0.107-_12_jan_2007_03_27)
Java HotSpot(TM) Server VM (build 1.8.0.107 jinteg:01.12.07-08:49 IA64, mixed mode)

To check the Java version on Windows

We can open the command prompt and the type

java -version

We can also find this using the below methods

Launch the Windows Start menu
Click on Programs
Find the Java program listing
Click About Java to see the Java version

or

Open control panel
Select Programs
Click Programs and Features

How to check if the Java is 32-bit or 64 bit

We can check the version command only. If it shows 64-bit, then it is 64 bit else is 32 bit

For 32 bit version, the heap size can be maximum 2Gb
For 64 bit version, the heap size can be much greater

How to check the location of the java

locate java
or
which java

How to compile the Java file

javac <java file>

I hope this article helps

See also  SQL trace, 10046 event in Oracle

Related Articles

Download Java

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top