img

Java Installation

Java is a high-level programming language originally developed by Sun Microsystems and released in 1995. Java runs on a variety of platforms, such as Windows, Mac OS, and the various versions of UNIX. This tutorial gives a complete understanding of Java. This reference will take you through simple and practical approaches while learning Java Programming language.

Java programming language was originally developed by Sun Microsystems which was initiated by James Gosling and released in 1995 as a core component of Sun Microsystems’ Java platform (Java 1.0 [J2SE]). The latest release of the Java Standard Edition is Java SE 8. With the advancement of Java and its widespread popularity, multiple configurations were built to suit various types of platforms. For example J2EE for Enterprise Applications, J2ME for Mobile Applications. The new J2 versions were renamed as Java SE, Java EE, and Java ME respectively.

Java is guaranteed to be Write Once, Run Anywhere.

Setting up Java Environment in your local machine

  • Java Download: Go to Oracle site and download Java suitable for your OS and version. Java 9 is the latest version from the Java and you can download it from here.

Note: Before Java9, it has two different versions for Windows installation, i.e. 32-bit & 64-bit. From Java9 it has the only a single installation file for both 32-bit & 64-bit.

  • After successfully downloaded the installation file, double click on the downloaded exe file and follow the steps. Normally they already set up the best configuration for you in installation.

Note: It may take time around 5-10 minutes for installation, depending upon your OS and system configurations

Once the installation is completed, you can verify the Java installation from the terminal or cmd. Type below command to verify the installed Java Version

java -version

If Java9 is successfully installed, you can see the result like below.

java version "1.9.0_211"
Java(TM) SE Runtime Environment (build 1.9.0_211-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.211-b12, mixed mode)

If the terminal isn’t finding java keyword, check – you may not have followed proper steps above

Setting up Java Environment variables

If in case you can’t find the java keyword by the command in cmd or Terminal, try to set up the environment variables for Java will work for you. Set the following user environment variables

  • JAVA_HOME : C:\Program Files\Java\jdk1.8.0_112
  • JDK_HOME: %JAVA_HOME%
  • JRE_HOME: %JAVA_HOME%\jre
  • CLASSPATH : .;%JAVA_HOME%\lib;%JAVA_HOME%\jre\lib
  • PATH: your-unique-entries; %JAVA_HOME%\bin (make sure that the longish your-unique-entries does not contain any other references to another Java installation folder)

Notice that these environment variables are derived from the “root” environment variable JAVA_HOME. This makes it easy to update your environment variables when updating the JDK. Just point JAVA_HOME to the fresh installation

  • Facebook
  • Twitter
  • Google+
  • Linkedin
  • Pinterest

Leave a Comment

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.

It is main inner container footer text