How to install Java JRE (Debian 9 / Ubuntu 18.04)

Introduction

In this article we want to show you how to install Java JRE on your virtual server server. Java is required for some software and can be installed in few seconds with this simply article. An example of a Java application would be for example game servers such as Minecraft which require Java. In this article we install the default packages of Java which are delivered with Debian 9 and Ubuntu 18.04.


Step 1 - Update Packages

Before you will install Java it is important that all packages are up to date so that the latest Java version is also installed. This can you do with the following command.

Shell-Script
  1. sudo apt-get upgrade

Step 2 - Install Java Default JRE

After updating the packages you can easily install Java with the following command.

Shell-Script
  1. sudo apt install default-jdk

Now Java is installed and can be used for different applications.