This howto describe how to run wget behind authenticated proxy to download files. GNU Wget is a package for retrieving files using HTTP, HTTPS and FTP, the most widely-used Internet protocols. It is a non-interactive commandline tool, so it may easily be called from scripts, cron jobs, terminals without X-Windows support, etc.
GNU Wget comes as default software with almost every distribution, so we are going to just configure it to start downloading using authenticated proxy.
1) Export http_proxy variable
2) Export http_proxy variable in bash login script
3) Define Proxy User / Pass in .wgetrc
[root@centos1 ~]# wget http://www.rarlab.com/rar/rarlinux-3.8.0.tar.gz
Resolving proxy01.sohailriaz.com… 10.1.59.81
Connecting to proxy01.sohailriaz.com|10.1.59.81|:80… connected.
Proxy request sent, awaiting response… 200 OK
Length: 791915 (773K) [application/x-gzip]
100%[=======================================>] 791,915 88.8K/s in 11s
08:47:04 (70.7 KB/s) - rarlinux-3.8.0.tar.gz’ saved [791915/791915]
Enjoy Brothers 🙂
» Linux, Programming / Scripting » HowTo Wget behind Authenticated Proxy
8 Responses to HowTo Wget behind Authenticated Proxy
Leave a Reply
« How To Configure Yum Behind Authenticated Proxy Server HowTo SSH outside using Authenticated Proxy »
keep it up
thanks alot for sharing such good knowledge.
How to configure the POP TOP On RHEL 5 by using the the two lancard Scenario.
as well as i want to configure the Proxy Squid on the Same Machine.
One is local and other will use the Live IP.
Can someone give me the step by step instruction.
Waitinf for the Urgent response.
proxy_pass is now proxy_password on RHEL6
Thanx for the info about setting http_proxy. Even man pages of wget does
not list this option. I landed upon your blog and learned it. But your blog
has an error, i.e., proxy_pass. It should be proxy_password. I tried it
on FC14 and failed and was successful only when I changed to
proxy_password which is listed in the wget man pages.
Nevertheless thanks again for your efforts in imparting knowledge
to your friends world over.
Dear Sohail Riaz,
I am in the middle of learning configuring IPV6 on FC14. I wish use this
FC14 box as IPV6 router. The box has 2 ethernet interfaces. Please help
Mine worked with proxy_passwd = my_password
[…] HowTo Wget behind Authenticated Proxy | … – This howto describe how to run wget behind authenticated proxy to download files. GNU Wget is a package for retrieving files using HTTP, HTTPS and FTP, the most […]