Updating java in ubuntu
There are two versions of the Java Runtime Environment available. This version is not available via the "Ubuntu Software" tool which is generally used for installing applications in Ubuntu.The Oracle website doesn't include a Debian package either.Snap Packages provide a way of installing an application along with all of its dependencies in a container so that there are no conflicts with other libraries and the application is almost guaranteed to work.However snap packages do not exist for all applications so you will need to install a version of Java yourself.There are now 2 further options: The Java JDK installs just the Java Development Kit.The Netbeans option installs a full development integration environment as well as the Java Development Kit.
Look for the link called "Java SE" which takes you to this page.The second command provides a directory listing of all the files beginning with "jdk".The next step is to navigate to the place where you plan to install the development kit and extract the zipped up tar file.As with the Java Runtime Environments the Java Development Kits are available as an official Oracle package or an open source package.
This guide will show you how to install both the official Oracle Runtime and Development Kits as well as the open source alternatives.
After the relevant file has download open a terminal window.