ML
    • Recent
    • Categories
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    How To Download Oracle Java Directly to Server without Clicking Accept

    IT Discussion
    cli command line wget oracle oracle java java linux
    2
    3
    1.2k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • scottalanmillerS
      scottalanmiller
      last edited by

      If you've ever had to download Oracle's Java products, you are likely aware that you have to go to their web page, in a web browser, click accept to their license terms and then download the product. This, obviously, cannot be done on a server because you need a GUI to do this. A bit of a pain.

      There is a way to handle this from the command line. Find the download link that you want to use and use this wget command to prefix it...

      wget --header "Cookie: oraclelicense=accept-securebackup-cookie"
      

      So for example, for the latest Java 9 download, this is the full command to run from your server's command line:

      wget --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/9+181/jdk-9_linux-x64_bin.rpm
      

      There you go, handle CLI based Oracle Java downloads.

      1 Reply Last reply Reply Quote 7
      • coliverC
        coliver
        last edited by

        This is more helpful then you realize.

        scottalanmillerS 1 Reply Last reply Reply Quote 0
        • scottalanmillerS
          scottalanmiller @coliver
          last edited by

          @coliver said in How To Download Oracle Java Directly to Server without Clicking Accept:

          This is more helpful then you realize.

          I needed it today, so I'm pretty aware how useful it is 🙂

          1 Reply Last reply Reply Quote 1
          • 1 / 1
          • First post
            Last post