![]() Sudo update-alternatives -set javac /usr/lib/jvm/jdk-11.0. Sudo update-alternatives -set jar /usr/lib/jvm/jdk-11.0.11/bin/jar ![]() Sudo update-alternatives -install /usr/bin/javac javac /usr/lib/jvm/jdk-11.0.11/bin/javac 2 Select the desired version from prompt if here are multiple java versions already installed and run following commands sudo update-alternatives -install /usr/bin/jar jar /usr/lib/jvm/jdk-11.0.11/bin/jar 2 Run command sudo update-alternatives -install /usr/bin/java java /usr/lib/jvm/jdk-11.0.11/bin/java 2 Refresh the new configuration with source ~/.bashrcĮnter he command java-version and you can see the version installed ORĬonfigurations in (step 3 - step 5 )also can be done by using below method as well Sudo nano ~/.bashrc and add following lines JAVA_HOME=/usr/lib/jvm/jdk-11.0.11/ Overview The Java Runtime Environment (JRE) is required to run Java programs. Sudo nano /etc/environment and add the line JAVA_HOME="/usr/lib/jvm/jdk-11.0.1/" Installing OpenJDK JRE Installing Oracle HotSpot JRE 1. This installation involves 2 steps: adding the repository to our system and installing the package from the repository via apt: sudo add-apt-repository ppa:linuxuprising/java sudo apt update sudo apt install oracle-java11-installer. ![]() Once it is installed set the JAVA_HOME in environment Currently, Oracle JDK 11 is also available in a PPA (personal package archive). ![]() Install the package by double clicking on it. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |