How to install Java on Ubuntu with apt

Поделиться
HTML-код
  • Опубликовано: 21 авг 2024
  • Want to install Java on Ubuntu in the fastest way possible? Just use Ubuntu apt to install Java with the default JDK, and the installation will go quickly and without issue.
    The only drawback? You may not get the latest version of Java installed on Ubuntu. Right now, with Ubuntu 22, Java 11 is the default JDK installed with apt. That's a bit behind the times because Java 17 is the latest long term support (LTS) release.
    But if you just need to run Java applications or compile some Java code, this is the best way to setup Java on Ubuntu. It's fast, it's easy, and you'll get Java installed on Ubuntu quickly and easily.

Комментарии • 25

  • @MaroofAhmed-ng7od
    @MaroofAhmed-ng7od Год назад +2

    Searched so many videos and googled literally for 1 hour. But could not find the resolve until I found this vid. Thank you so much.

    • @cameronmcnz
      @cameronmcnz  Год назад

      That's so great to hear!
      What are you using Java for?

  • @tiago530
    @tiago530 9 месяцев назад +1

    Hi Cameron! You probably do not know how much you helped me today. I am a beginner on Linux, and I had to hard reset my Linux two times, because I was failing at Java installation. In the first hard reset I choose a easier Linux Distro. And your video helped me to install Java and set as $JAVA_HOME. Anyway, I wish that Jesus bless you and, thanks for helping us!

    • @cameronmcnz
      @cameronmcnz  9 месяцев назад +1

      Super happy I was able to help you out!
      It all gets easier from here!

  • @Flome
    @Flome Год назад +1

    Great video but I believe that you're supposed to write the JAVA_HOME variable without the /bin/java part

  • @madhavmayande6732
    @madhavmayande6732 Год назад +1

    Thanx

  • @venukumarkodari6289
    @venukumarkodari6289 11 месяцев назад +1

    This is great video. Worked like ice for me. Thank you.

    • @cameronmcnz
      @cameronmcnz  11 месяцев назад

      Glad this still works!
      I'll be updating the Ubuntu and the JDK for the Java 21 release later next week!

  • @Whimsickle_
    @Whimsickle_ Год назад

    OMD THANK YOU I AM NEW TO UBUNTU AKA LINUX THANK YOU

  • @boli1417
    @boli1417 10 месяцев назад

    sorry may ask you a question. When i type sudo nano /etc/enviorment, it opens nano but there is no PATH and when i put JAVA_HOME and exeute echo JAVA_HOME, it displays command not found

  • @SinNombre101
    @SinNombre101 8 месяцев назад

    The JAVA_HOME variable in the "/etc/environment" file should point to the directory containing the Java installation, not directly to the "java" executable.
    Therefore, the correct configuration would be:
    JAVA_HOME="/usr/lib/jvm/java-11-openjdk-amd64/"

  • @belenrb
    @belenrb Год назад +2

    Thank you!!

    • @cameronmcnz
      @cameronmcnz  Год назад

      Always here to help. Even if I am a bit slow on the replies.

  • @hotnigga_
    @hotnigga_ Год назад

    sir please at the GNU nano i receive a permission denied message please help

  • @hyunkelhurashima149
    @hyunkelhurashima149 Год назад

    Thank you SO MUCH

  • @metinyekduman109
    @metinyekduman109 2 года назад

    Thank you

  • @arijitchakrabarty1552
    @arijitchakrabarty1552 Год назад

    How to install jdk 15?

  • @BiranchiNarayanRana
    @BiranchiNarayanRana 3 часа назад

    2024 mein kaun kaun dekh rahe ho!?? 😅

  • @tymo3391
    @tymo3391 Год назад

    Well done

  • @dmytromorozov22
    @dmytromorozov22 11 месяцев назад

    Great tutorial! Дякую!

  • @lapisfix
    @lapisfix 9 месяцев назад

    cheers great video

  • @domaincontroller
    @domaincontroller Год назад

    00:46 default jdk