How to wget via proxy
This is how I use wget via proxy. It goes like this. You set http_proxy to refer to your proxy setting and from there you just issue wget command.
[user@localhost ~]$ export http_proxy=http://username:password@proxyaddress:proxyport/
[user@localhost ~]$ wget [someoption] [download_link]
Note: if your proxy doesn’t require authentication, just omit the username & password part in http_proxy. Like this..
[user@localhost ~]$ export http_proxy=//proxyaddress:proxyport
For some reasons unknown to me, the above method no longer working (at least in my case). I got this error
Error parsing proxy URL http://username:password@proxyaddress:proxyport/: Bad port number.
It seems that my username or password can’t be parsed. My solution is just set the http_proxy without username & password and then enter my username and password through wget option. And it works(Yay!).
[ferry@lenovog480 ~]$ http_proxy=http://proxyaddress:proxyport/
[ferry@lenovog480 ~]$ wget --proxy-user=myusername --proxy-password=mypassword [someoption] [download_link]