0

I am running Ubuntu 15.10. I can see that i am able to access internet through firefox when I allow 'Auto detect proxy settings for this network' but the system services, like apt-get, etc. are unable to connect to the internet. Please help.

1 Answer 1

0

You need to manually configure your proxy server for apt-get. First check what is the address of the server, then type:

sudo echo 'Acquire::http::proxy "http://<proxy>:<port>";' > /etc/apt/apt.conf

Replace <proxy> and <port> with your settings.

To add proxy for HTTPS and FTP protocols use (mind the double character >>):

sudo echo 'Acquire::https::proxy "https://<proxy>:<port>";' >> /etc/apt/apt.conf
sudo echo 'Acquire::ftp::proxy "ftp://<proxy>:<port>";' >> /etc/apt/apt.conf

If your proxy server requires authentication, precede the address with username and password according to your settings.


Your /etc/apt/apt.conf file should look like this in the end:

Acquire::http::proxy "http://<username>:<password>@<proxy>:<port>";
Acquire::https::proxy "https://<username>:<password>@<proxy>:<port>";
Acquire::ftp::proxy "ftp://<username>:<password>@<proxy>:<port>";

You must log in to answer this question.

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