Skip to content

Commit

Permalink
OK
Browse files Browse the repository at this point in the history
  • Loading branch information
james-ch-tung committed Dec 18, 2016
1 parent 3bf0f2f commit eb0a9bc
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions How-to-handle-license-when-downloading-Java-JDK-on-Linux.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
UPDATED FOR JDK 8u112
RPM:

wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u112-b15/jdk-8u112-linux-x64.rpm
TAR GZ:

wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u112-b15/jdk-8u112-linux-x64.tar.gz
RPM using curl:

curl -v -j -k -L -H "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u112-b15/jdk-8u112-linux-x64.rpm > jdk-8u112-linux-x64.rpm
In all cases above, subst 'i586' for 'x64' to download the 32-bit build.

-j -> junk cookies
-k -> ignore certificates
-L -> follow redirects
-H [arg] -> headers
curl can be used in place of wget.

UPDATE FOR JDK 7u79

TAR GZ:

wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/7u79-b15/jdk-7u79-linux-x64.tar.gz
RPM using curl:

curl -v -j -k -L -H "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/7u79-b15/jdk-7u79-linux-x64.rpm > jdk-7u79-linux-x64.rpm
Once again, make sure you specify the correct URL for the version you are downloading. You can find the URL here: Oracle JDK download site

ORIGINAL ANSWER FROM 9th June 2012

If you are looking to download the Oracle JDK from the command line using wget, there is a workaround. Run the wget command as follows:

wget --no-cookies --header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com" "http://download.oracle.com/otn-pub/java/jdk/7/jdk-7-linux-x64.tar.gz"
Be sure to replace the download link with the correct one for the version you are downloading.

0 comments on commit eb0a9bc

Please sign in to comment.