This Video Tutorial Explains how to Download, Install, and Configure Java Development Kit. It includes Java 64 bit, Java 8 Download and Steps to Uninstall it as well:
In order to develop Java programs and applications, we need to have a development environment on our machine that can create, compile and execute Java programs.
What You Will Learn:
Java Download & Installation
The Java Development Kit (JDK) comes bundled with software and tools required to compile, debug and execute applications written in Java. In addition, JDK also has other primary components, a collection of programming tools like javac, jar, and archiver that are used to package related class libraries in one JAR file.
The JDK also comes with a complete runtime environment referred to as “Java Runtime Environment” or JRE containing Java Virtual Machine (JVM) and other important class libraries helpful to developers as well as production.
We need to download the JDK for a particular version of Java and then install it so that we have a Java development environment on our machine.
This video tutorial provides detailed instructions to download and install the Java Development Kit and other settings to have a complete development environment.
How to Download & Install Java and Eclipse IDE:
Java 64-bit Download
Here is the official site to download the latest Java version for any operating system.
Under the “downloads” tab on this site, we can find the required Java (JDK) version that we want to download.
Once the “Download” button is clicked, the following chart that shows the available versions for different Operating Systems is displayed.
Click the radio button “I accept license…” and then click on the required version (archived or .exe file) for appropriate OS. (Here we choose windows 64-bit version of jdk13).
Note that most of these are “Offline Installers” i.e. we need not be connected to the internet while installing Java using these installers. All the required files are packaged in the installer file.
Java 8 Download
If you want to download a specific Java version like Java 8, then you can download it from the official site.
For Example, Click this link, to download Java 8.
The following list of releases will be shown for download:
Then you can select the required installable and download it. Once the installable is downloaded, now we need to install Java.
Note: In this tutorial, we will see the steps to install JDK 13. Note that we have to follow similar steps to install other versions of Java including Java 8.
Install Java 64 bit Version
The steps to install Java are as follows:
#1) Double-click on the .exe just downloaded and the following dialog appears.
#2) The user is prompted to select the installation directory.
Select the appropriate installation directory and click “Next”.
#3) Now the Java installation begins as shown in the progress dialog below.
#4) When the installation finishes, the following dialog is displayed.
Click “Close” and Java is successfully installed. Once Java is successfully installed on the computer, we need to set a few environment variables which we will do next.
Configuring Java Environment Variables
The “Path” and “Classpath” variables give the location of “bin” and “lib” folders of Java respectively. By specifying these values, we can directly call Java compiler “javac” or any other lib or other files without having to specify the entire file path every time.
#1) Click on My Computer => Properties. The following dialog will be displayed.
As shown by the red arrow, click “Advanced system settings”.
#2) The following dialog box appears where you can see the “Environment Variables…” tab as pointed by the arrow.
#3) Click on the “Environment Variables…” tab and you will see the following dialog.
We have to add/edit the “Path” and “ClassPath” variables (marked as 1 and 2) in this dialog.
#4) First, let us set the “Path” variable. We have to set the “Path” variable to the path given by the Java/bin folder. To get this path, navigate to the java installation directory and copy the bin folder path as shown below.
Once the bin path is copied, we have to set it to the “Path” environment variable. For this, check the “user variables” section in the above dialog and if the “Path” variable already exists, then select it and click “Edit…”.
The following dialog appears.
Now update the just copied “bin” folder path in this dialog (enclosed in red) and click OK.
#5) If the “Path” variable does not exist in the “user variables” section, then we can create a new variable and set its value to the bin folder path as shown below.
#6) Once the “Path” variable is set, we can also set the “Classpath” variable in the “System variables” section in a similar manner. We need to set the “Classpath” variable to the lib folder path.
#7) To do this, first copy the “lib” folder path as shown below.
#8) Now check if the “Classpath” variable is already present. If it is, then select it and click edit. Copy the lib path as shown below.
Click OK and the lib path is set.
#9) If the “Classpath” variable is not present then we can create a new variable and set the lib path as its value as we have done for the “Path” variable.
#10) Now your JDK environment should be set. To check this, open the command prompt window and give the command “javac”. If the Java version is properly installed, then you will see the following output in the command prompt.
Now your Java version is successfully installed on your machine.
Once Java is installed on our machine successfully, we can install any Java IDE like Eclipse and start developing programs.
The following steps should be followed to uninstall Java from your computer.
- Click “Start”.
- Select “Settings”. A dialog box will be displayed.
- In the “Settings” dialog, select “Apps & Features”.
- A list of the installed apps and products will be displayed. Select the Java version installed and click “Uninstall”. This is shown in the below dialog.
Once Java is completely uninstalled, the message will be displayed to indicate that.
- The above uninstall steps are for Windows 10 operating system.
- We might have to manually remove the values we set in “Path” and “Classpath” variables. They are not removed by the installer.
This tutorial explained about the download, installation, configuration, and uninstallation of Java Development Kit. Note that all the actions were carried out on the Windows 10 operating system.
The steps are similar for the other versions of Windows OS.