6

I'm using Ubuntu 16.04 and I cannot unset the http_proxy permanently. Every time I open a terminal window, it is restored to http://127.0.0.1:1080.

I have checked /etc/environment, ~/.profile, ~/.bashrc and the scripts inside /etc/profile.d but find nothing about proxy.

So now I want to know how to find out where-in which file-an environment variable is defined. I mean something like where http_proxy and it prints /etc/blahblah(the path of the file that defines http_proxy).

3

1 Answer 1

-2

Just add to .bashrc a line with export http_proxy="<proxy you want to use>". This way each time you will run a new shell, this proxy will be in use, same for https and ftp proxy

3
  • But I want to find out in which file http_proxy is defined, not how to define it.
    – zwcloud
    Apr 9, 2017 at 7:05
  • In Centos this should be in /etc/bashrc, find similar file in /etc or in /usr. But as far as I know by default this variable is not set in linux, additionally you can check does new user has this variable set to the same value.
    – darvark
    Apr 9, 2017 at 7:09
  • I'm using Ubuntu. But thanks for the information.
    – zwcloud
    Apr 9, 2017 at 7:11

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