Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When i try to install something it gives me this error:

HTTP request sent, awaiting response... 403 Forbidden 2014-04-23 09:32:53 ERROR 403: Forbidden.

download failed

Oracle JDK 7 is NOT installed........

But i have Oracle JDK 7 installed :

mostafa@mostafa-EP31-DS3L:~$ sudo update-alternatives --config java

0 /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java 1061 auto mode

1 /usr/lib/jvm/java-6-openjdk-amd64/jre/bin/java 1061 manual mode

* 2 /usr/lib/jvm/java-7-oracle/jre/bin/java 1 manual mode

Press enter to keep the current choice[*], or type selection number:

what is the problem and how can i resolve this?

share|improve this question
up vote 2 down vote accepted

as you know oracle bans some countries and ... first add key:

sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update

then use apt-install to install the package:

sudo apt-get install oracle-java7-installer

after getting error 403, use ls:

ls /var/cache/oracle-jdk7-installer/

jar.binfmt  jdk-7u55-linux-x64.tar.gz  wgetrc

copy .tar.gz filename and search/download it in the web (

then copy downloaded file to cache:

sudo cp ~/Downloads/jdk-7u55-linux-x64.tar.gz /var/cache/oracle-jdk7-installer/

to ensure that you download the correct file, use md5sum:

md5sum jdk-7u55-linux-x64.tar.gz
9e1fb7936f0e5aaa1e64d36ba640bc1f jdk-7u55-linux-x64.tar.gz

result must match with oracle checksum at

after this if you run the install command, installation will be done correctly using cached file:

sudo apt-get install oracle-java7-installer
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.