Super User is a question and answer site for computer enthusiasts and power users. 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

I am trying to install Java on Ubuntu 12.04 but facing some problems doing it from the command line.

When I tried to add the repository using this command, I get errors:

$ sudo apt-add-repository ppa:flexiondotorg/java
Traceback (most recent call last):                 
  File "/usr/bin/apt-add-repository", line 125, in <module>             
    ppa_info = get_ppa_info_from_lp(user, ppa_name)             
  File "/usr/lib/python2.7/dist-packages/softwareproperties/ppa.py", line 80, in          get_ppa_info_from_lp                                  
    curl.perform()                                      
pycurl.error: (6, "Couldn't resolve host 'launchpad.net'")
share|improve this question

migrated from stackoverflow.com Sep 28 '12 at 16:23

This question came from our site for professional and enthusiast programmers.

    
with Java you mean what ? – Ken Sep 28 '12 at 14:37
    
@H2CO3 askubuntu.com – Ken Sep 28 '12 at 14:38
    
i mean jdk package – akash Sep 28 '12 at 14:38
2  
askubuntu.com/a/89098 – Ken Sep 28 '12 at 14:41
    
"Couldn't resolve host 'launchpad.net'" This error seems pretty self-explanatory.. Can you resolve, ping and connect to that hostname? – Mxx Sep 29 '12 at 4:01

If you have a gui login then you can try this, under System Settings > Software Sources > Other Software

Click on Add... and paste ppa:flexiondotorg/java

You will find that two new entries are now part of the repo list. Now you can go ahead and do an apt-get update followed by apt-get install.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .