When I try to download Java from Oracle I instead end up downloading a page telling me that I need agree to the OTN license terms.
Sorry!
In order to download products from Oracle Technology Network you must agree to the OTN license terms.
Be sure that...
- Your browser has "cookies" and JavaScript enabled.
- You clicked on "Accept License" for the product you wish to download.
- You attempt the download within 30 minutes of accepting the license.
How can I download and install Java?
Why not click to download from your browser then copy & paste the exact link where it was downloaded, for example:
You can find out the link by looking at the network tab of your browser after accepting terms in oracle and clicking to download. F12 in Chrome. Firebug in Firefox.
I know that Oracle made everything possible to make their Java Runtime and Java SDK as hard as possible.
Here are some guides for command line lovers.
For Debian like systems (tested on
Debian
squeeze andUbuntu
12.x+)Note: if you know a better or easier way add a comment, I will update the guide.
Oracle has put a prevention cookie on the download link to force you to agree to the terms even though the license agreement to use Java clearly states that merely by using Java you 'agree' to the license..
The method that Oracle wants is you to download it with an agreement. After that, this script cn be modified for your specific Linux
Downloading Java from the command line has always been troublesome. What I have been doing reciently is to use FireFox (other browsers might work) to get a download started on my laptop, pause it (within the Downloads windows), use the "Copy Download Link" menu item of the context menu displayed for the downloading file. This URL can then be used on the Linux box to download the same file. I expect the URL has a short time to live. Ugly, but generally successful.
I've made a jdk-download script (specific for the tar.gz) for my gentoo boxes. Doesn't need to be updated like other similar scripts, trying to "brute-force" download the latest build for whatever version you want.
USAGE
Blog post
Source on bitbucket
Java SE Development Kit 8u191
TAR GZ:
RPM: