This question already has an answer here:

Cannot update pacman using sudo pacman -Syu under proxy network. I tried exporting environment variables using

export http_proxy='http://uem:12345@'

as my workplace network uses proxy and authenticaton.

and then updating using

sudo -E pacman -Syu

but it returns error 407and error: failed to synchronize any databases

marked as duplicate by G-Man, cuonglm, jimmij, Archemar, Gilles Jul 26 '15 at 21:08

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • You have a missing colon in-between http and // - not sure if that's a copy-and-paste error – DarkHeart Jul 26 '15 at 2:52
  • That really doesn't seem to be a duplicate of this at all. URI-encoding (from the comment) may be relevant, but the answers certainly won't be the same. – Michael Homer Jul 26 '15 at 8:17
  • I installed wget and added proxy settings to it, this seems to be the easiest possible way to do this, but then again it returns error 503. – Moithil Biswas Jul 26 '15 at 8:41

I can't duplicate your issue. sudo -E pacman -Syu with export http_proxy works for me.

I would check your user and password is correct (I know it is silly but humour me).

Test with curl or wget.

If you can get one of those to work you update pacman.conf:

XferCommand = /path/to/command %u

     If set, an external program will be used to download all remote
     files. All instances of %u will be replaced with the download URL.
     If present, instances of %o will be replaced with the local
     filename, plus a “.part” extension, which allows programs like wget
     to do file resumes properly.

     This option is useful for users who experience problems with
     built-in HTTP/FTP support, or need the more advanced proxy support
     that comes with utilities like wget.
  • Figured out the problem, it was simply the bandwith or say jus the network speed that was blocking me from doing this, now it works with both the way you said and the "export http_proxy..." way. – Moithil Biswas Jul 28 '15 at 20:38

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