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 was browsing through the apt folder to try my proxy settings and I was unable to find the apt.conf file in Ubuntu 11.04. Is there any alternative file for it?

Adding proxy settings to 99-synaptic in apt.conf.d does not help as it gets overwritten everytime I restart the system.

share|improve this question
up vote 11 down vote accepted

The /etc/apt/apt.conf file is still read if it exists. The apt configuration provided by packages is installed as separate files in /etc/apt/apt.conf.d/ so that it can be added and updated independent of any local changes you make in the main configuration file.

So if you have local configuration changes, just create the file.

share|improve this answer
so, lets say, i want a global proxy config that i want to add for cli and software centre (network proxy settings doesnt work for both, a well known fact!), where do i add that? previously adding proxy settings to apt.conf solved all problems! – Ubuntuser Apr 12 '11 at 11:07
Crrate a file in /etc/apt/apt.conf.d/ that has your addition. This has been available for several releases. It is a cleaner way of doing this kind of change. – BillThor Apr 12 '11 at 12:34
As I said, create the apt.conf file and add your settings there. It works identically to previous releases. – James Henstridge Apr 12 '11 at 15:07

Just add the following to /etc/apt/apt.conf and the problem is solved: sudo vi /etc/apt/apt.conf then add this to the first line:

Acquire::http::Proxy "http://proxy_address:8080/";
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.