In simple words, Java Virtual Machine (JVM) is a software platform developed by the OpenJDK project to provide virtual machine to run Java written programs. Actually, JavaVM is an interpreter for executing programs written in the Java programming language. It comes along with Java Runtime Environment (JRE) and Java Development Kit (JDK) packages made available by Oracle corporation, which are the commercial implementation of Java, based on the OpenJDK runtime.
In contrast to Java programs themselves, the JVM is not platform-independent, but a native program for the respective target platform. Java programs can be run on any system that has a JVM that meets the specifications.
After the source text has been converted into bytecode, it can be transferred to the JVM. This looks for the entry point of the program (in the case of Java the main () method) and starts execution there. To do this, the program block to be executed is first compiled for the target system and then called. The compilation takes place as a just-in-time compilation (JIT compilation).
To install JVM on Windows we need to executable files for JRE or JDK from the official of Java.
JRE: Jave runtime environment is a package of class libraries, loader class, and JVM, which altogether facilitates users to run Java programs.
JDK: Java Development Kit, as its name suggests, is meant for developers and comes with all necessary packages to help them in coding and running Java programs and applets.
Install Java virtual machine (JVM) for Windows 10 64-bit or 32-bit
Hence, to get the JVM on Windows 10, we either need JRE or JDK, the process of installing them is very easy just like any other Windows software.
- Visit Java.com for JRE and Oracle.com for JDK whereas those who are only interested in open-source JDK version can get OpenJDK from https://jdk.java.net/
- To download JRE with JVM for Windows 10 and click on Agree and Start Free Download button.
- This will automatically download the latest JRE version on your Windows 10 platform.
- If you are worried about the Java version then don’t be, the website will automatically detect the version of the browser and let you download 32-bit or 64-bit version accordingly.
- Once you have the Setup, double click on it to run the installation wizard.
- By default, the Java(TM) SE Runtime Environment and Java HotSpot(TM) 64-Bit Server VM will install in the C: Drive of Windows. If you want it somewhere else or in some particular folder then check the box given for “Change Destination folder“.
- To install simply click on the button given for it.
- Wait for seconds till the Setup decompress and install Java files on your Windows 10.
To check that everything is done correctly, open the command prompt and type:
C:\Users\h2s>java -version java version "1.8.0_281" Java(TM) SE Runtime Environment (build 1.8.0_281-b09) Java HotSpot(TM) 64-Bit Server VM (build 25.281-b09, mixed mode)