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

I'm trying to make the Update Manager work through the proxy on my ubuntu 9.10. I've tried what was suggested in this question, but the Update Manager still reports 409 conflict. Would really appreciate if anybody could help me with this.

The window manager solution turned out to simple: System->Administration->Synaptic package manager, then in the Synaptic window Settings->Preferences->Network. Manually enter the http_proxy field. And it works now. Still am curious as to how to do this from command line though.

share|improve this question
2 questions to make me understand your question better. 1. what is a 409 conflict ? 2. Are you unable to download packages via proxy even after creating /etc/apt/apt.conf.d/40proxy as explained in the post you have referred ? (If you clicked "Apply system-wide..." in Network Proxy after creating that file, it may get deleted) – koushik Oct 11 '10 at 13:16
2. yes, I'm unable to download packages after following your suggestions in that post. And yes, the file is there. – ev-br Oct 11 '10 at 14:00
1. No, I'm unable to download packages. When I start the Update Manager, Click "check", type the password, it fails to download anything and pops up an err window "Could not download all repository indexes". There it lists individual packages, like this: "Failed to fetch… 409 Conflict [IP: <ip here> 80]" – ev-br Oct 11 '10 at 14:03
@Zhenya can you successfully run apt-get update from the terminal? or do you get the same HTTP 409 error? – Riccardo Murri Oct 11 '10 at 18:55
@Riccardo Murri: same error, Err karmic/main Packages 409 Conflict " – ev-br Oct 11 '10 at 19:37

Proxy configuration in update-manager apparently happens at lines 179--228 of file /usr/share/pyshared/UpdateManager/Core/ (checked on Lucid, line numbers and file name may be different on other versions). Despite what the comment say, the code looks for proxy settings in this order:

  1. the Acquire::http::Proxy setting in /etc/apt/apt.conf
  2. The Synaptic::useProxy, Synaptic::httpProxy, Synaptic::httpProxyPort settings in /root/.synaptic/synaptic.conf
  3. the /system/http_proxy/* settings in gconf

The first one found sets the http_proxy environment variable for children processes (i.e., the ones that actually perform the update/upgrade).

Therefore, my advice would be to try adding this line to /etc/apt/apt.conf:

Acquire::http::Proxy "";

The exact syntax is documented in the apt.conf(5) man page

share|improve this answer
Thanks for a suggestion! Actually, I tried adding this line to /etc/apt/apt.conf before asking here. Right now the line is there (I recall I had to create the file manually), and it still doesn't work. – ev-br Oct 11 '10 at 19:41

Have you tried to modify .bashrc? Something like that:

$ sudo echo "export http_proxy=http://user:pass@ProxyAddress:ProxyPort" >> /etc/bash.bashrc
$ sudo echo "export ftp_proxy=ftp://user:pass@ProxyAddress:ProxyPort" >> /etc/bash.bashrc
share|improve this answer
yes, http_proxy and ftp_proxy env variables are set – ev-br Oct 11 '10 at 12:55

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.