3

When I use the command sudo apt-get update I get the error message Method gave invalid 400 URI Failure message. The odd thing is every time I use the command it crashes at a different spot.

For example:

$ sudo apt-get update
Ign http://dl.google.com stable InRelease                             
Ign http://archive.ubuntu.com saucy InRelease                         
Ign http://ppa.launchpad.net saucy InRelease                         
Hit http://dl.google.com stable Release.gpg                          
Ign http://archive.ubuntu.com saucy-updates InRelease                
Ign http://ppa.launchpad.net saucy InRelease                         
Hit http://dl.google.com stable Release                              
Ign http://ppa.launchpad.net saucy InRelease                          
Hit http://dl.google.com stable/main amd64 Packages                  
Ign http://ppa.launchpad.net saucy InRelease                         
Get:1 http://ppa.launchpad.net saucy Release.gpg [316 B]             
Ign http://archive.ubuntu.com saucy-security InRelease               
Get:2 http://ppa.launchpad.net saucy Release.gpg [316 B]             
E: Method gave invalid 400 URI Failure message 

Here is the output of wget -d http://ppa.launchpad.net/ -o /tmp/outputfile.log:

$ wget -d http://ppa.launchpad.net/ -o /tmp/outputfile.logSetting --output-file (logfile) to /tmp/outputfile.log

DEBUG output created by Wget 1.14 on linux-gnu.

URI encoding = ‘UTF-8’
--2014-07-10 13:48:37--  http://ppa.launchpad.net/ Resolving ppa.launchpad.net (ppa.launchpad.net)... 91.189.95.83 Caching ppa.launchpad.net => 91.189.95.83 Connecting to ppa.launchpad.net (ppa.launchpad.net)|91.189.95.83|:80... connected. Created socket 4. Releasing 0x0000000000f3dde0 (new refcount 1).

---request begin--- GET / HTTP/1.1 User-Agent: Wget/1.14 (linux-gnu) Accept: */* Host: ppa.launchpad.net Connection: Keep-Alive

---request end--- HTTP request sent, awaiting response... 
---response begin--- HTTP/1.1 200 OK Date: Thu, 10 Jul 2014 12:48:40 GMT Server: Apache/2.2.22 (Ubuntu) Vary: Accept-Encoding Keep-Alive: timeout=5, max=100 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: text/html;charset=UTF-8

---response end--- 200 OK Registered socket 4 for persistent reuse. URI content encoding = ‘UTF-8’ Length: unspecified [text/html] Saving to: ‘index.html’

     0K .......... .......... .......... .......... .......... 7.72K
    50K .......... .......... .......... .......... .......... 13.3K
   100K .......... .......... .......... .......... .......... 12.6K
  1850K .......... .......... .......... .......... .......... 19.2K
  1900K .......... .......... .......... .......... .......... 8.97K
  1950K .......... .......... .......... .......... ...       
18.2K=2m34s

2014-07-10 13:52:18 (12.9 KB/s) - ‘index.html’ saved [2041092]

Here are my locale information:

$ locale
LANG=en
LANGUAGE=en
LC_CTYPE="en_CA.utf8"
LC_NUMERIC="en_CA.utf8"
LC_TIME="en_CA.utf8"
LC_COLLATE="en_CA.utf8"
LC_MONETARY="en_CA.utf8"
LC_MESSAGES="en_CA.utf8"
LC_PAPER="en_CA.utf8"
LC_NAME="en_CA.utf8"
LC_ADDRESS="en_CA.utf8"
LC_TELEPHONE="en_CA.utf8"
LC_MEASUREMENT="en_CA.utf8"
LC_IDENTIFICATION="en_CA.utf8"
LC_ALL=en_CA.utf8
9
  • Most of the (old) responses to this indicate that it may be a connection problem between you and the archive servers - has something changed in a proxy, or at your ISP? Jul 8, 2014 at 15:49
  • I am a novice so I can't comment on the state of my proxy but my internet connection is still active. How do I go about diagnosing my connection ?
    – Bromo98
    Jul 9, 2014 at 8:01
  • Unfortunately no, I don't know how to do that Jul 9, 2014 at 13:26
  • try wget -d http://ppa.launchpad.net/ -o /tmp/outputfile.log and post the output, maybe we'll find information about what went wrong.
    – Lety
    Jul 10, 2014 at 11:51
  • Thanks for the chime in folks. I have tried the wget command and updated the original entry with its output. Does it shed a light?
    – Bromo98
    Jul 10, 2014 at 13:02

1 Answer 1

0

Your locale encoding settings is utf8 instead of UTF-8.

try this command:

   sudo locale-gen en_CA.UTF-8

exit from terminal and re-login (I'm not sure if you have to reboot).

Check if locale settings are correctly modified and try perl and apt-get command.

You must log in to answer this question.

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