I'm trying to get JDK 1.6 using the following command:
wget 'http://download.oracle.com/otn/java/jdk/6u14-b08/jdk-6u14-linux-x64.bin'
The download fails and I suspect it's related to the fact that the website requires you to accept the license agreement. Is there a way to accept the agreement and receive the file?
I will go ahead and post it just in case....Please note however that these instruciton install Java7 NOT Java6
cut and paste from http://www.webupd8.org
This is a excerpt of my answer to this question.
The PPA that you install with thesecommands only points to the Java website to make installing easier, it does not contain Java itself. Oracle changed the license and now it can not be hosted anywhere and can only be downloaded directly from Oracle..
HERE is an older post from the same site that gives more information on this change as well as more information on Java7 itself and how to remove it , check for and select which version is running.
If you accept the agreement once you can then use the
--load-cookies FILE
option towget
to get it to use the saved cookie (e.g. from your .mozilla folder) to do the download. I don't see another way of doing it.So
wget --load-cookies ~/.mozilla/firefox/XXXX.default/cookies.txt URL
Caveat
Only works with old firefox cookies store - not the new sqlite backend.
Alternative
Alternatively you can install the Sun JDK from the repos as TrailRider hinted at - the license agreement is done during the install.