I have tried to set the proxy in the bash_profile:

export http_proxy=http://UserID:PWD@

export https_proxy=http://UserID:PWD@

export ftp_proxy=http://UserID:PWD@

Also since my password contains an '@' symbol I escaped it with \ and also tried to replace it with %40.

And I am saving the changes and updating the profile using source ~/.bash_profile

Despite all this, when I run the command:

sudo pip install kmeans-smote

I get Proxy Authentication Error:


Any help would be appreciated. Thanks!


Variables in bash are case sensitive and most software expects the proxy to be set in uppercase. It's also a good idea to quote strings as you never know what can upset bash.

export HTTP_PROXY="http://UserID:PWD@"

export HTTPS_PROXY="http://UserID:PWD@"

export FTP_PROXY="http://UserID:PWD@"

NOTE For these sort of shell questions Stack Overflow is usually better for a quick answer.

  • This isn't working either. – n.gaurav Feb 12 at 14:42

You must log in to answer this question.

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