Skip to content

A Bash Shell script that will install Oracle JDK, after you download it from oracle.com

License

Notifications You must be signed in to change notification settings

gzachos/oraclejdk-debian-installer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

oraclejdk-debian-installer

A Bash Shell script that will install Oracle® Java SE JDK (see notes below), after you download it from oracle.com.

Operating System

LINUX // Debian-based distributions
(Developed on Linux Mint 18)

Shell

  • Bourne Again SHell (Bash)

Developer

George Z. Zachos

License

GNU GENERAL PUBLIC LICENSE Version 2, June 1991

Notes

  • This script was developed in order to cover personal needs and it is by no mean guaranteed to work properly on every system.
  • This script does support installation of Oracle® JDK 9 and Oracle® JDK 10!
  • Oracle® has proposed a new version scheme for Oracle® based builds (YY.M) starting in March, 2018. Java SE 10 (18.3) will be a short term release and users should transition to the next release when available.

Execution

There are two ways that you can execute this script.

  • 1st way:
sudo ./installOracleJDK.sh

In order to use this way, you have to download the '.tar.gz' file of your choice from oracle.com and save it inside the Downloads directory of your account. After download is complete, run the above command. During execution you will be asked to enter your username (username@host), in order for the script to enter /home/username/Downloads/ and search for the file to be installed.

  • 2nd way:
sudo ./installOracleJDK.sh [absolute-path-of-directory]

This way allows you to provide the absolute path of the directory containing the '.tar.gz' file as a command line argument, in order to override the default option.

Command example:

sudo ./installEOracleJDK /home/gzachos/Desktop/

In case more than one '.tar.gz' files exist inside the specified directory, you will be prompted just like it is shown in the screenshot below, to choose the one you want to be installed.

e.g.
Prompt