Linux
無法 wget 到 ftp 伺服器
我正在嘗試從遠端機器獲取 ftp 伺服器。命令沒有過去
'Logging in as anonymous'
。這就是我得到的。wget ftp://hgdownload.cse.ucsc.edu/goldenPath/hg19/chromosomes/chr1.fa.gz --2013-09-29 22:07:53-- ftp://hgdownload.cse.ucsc.edu/goldenPath/hg19/chromosomes/chr1.fa.gz => ‘chr1.fa.gz’ Resolving proxy.x.y.z... *.*.*.* Connecting to proxy.x.y.z|*.*.*.*|:3128... connected. Logging in as anonymous ...
當我嘗試從遠端機器通過 Firefox 訪問該站點時,它工作正常。我已經像這樣設置了我的 ftp 代理
export ftp_proxy="ftp://a.user:password@proxy:3128
誰能幫我解決這個問題?
謝謝
你試過這樣設置代理環境嗎?(http:// 而不是 ftp://)
$ export ftp_proxy=http://a.user:password@proxy.domain:3128
你也可以用其他方式,請創建一個文件 ~/.wgetrc 包含以下設置:
http_proxy = http://a.user:password@proxy.domain:3128 ftp_proxy = http://a.user:password@proxy.domain:3128 proxy_user = username proxy_password = password use_proxy = on
該連結成功地為我工作。
$: wget <ftp://hgdownload.cse.ucsc.edu/goldenPath/hg19/chromosomes/chr1.fa.gz–2013-09-30>
23:34:58-- ftp://hgdownload.cse.ucsc.edu/goldenPath/hg19/chromosomes/chr1.fa.gz => `chr1.fa.gz.1' Resolving hgdownload.cse.ucsc.edu (hgdownload.cse.ucsc.edu)... 128.114.119.163 Connecting to hgdownload.cse.ucsc.edu (hgdownload.cse.ucsc.edu)|128.114.119.163|:21... connected. Logging in as anonymous ... Logged in! ==> SYST ... done. ==> PWD ... done. ==> TYPE I ... done. ==> CWD (1) /goldenPath/hg19/chromosomes ... done. ==> SIZE chr1.fa.gz ... 73773666 ==> PASV ... done. ==> RETR chr1.fa.gz ... done. Length: 73773666 (70M) (unauthoritative) 3% [=> ] 2,810,568 101K/s eta 10m 57s
在我的
/etc/wgetrc
passive_ftp = on
$: wget --version
GNU Wget 1.13.4 built on linux-gnu. +digest +https +ipv6 +iri +large-file +nls +ntlm +opie +ssl/openssl Wgetrc: /etc/wgetrc (system) Locale: /usr/share/locale Compile: gcc -DHAVE_CONFIG_H -DSYSTEM_WGETRC="/etc/wgetrc" -DLOCALEDIR="/usr/share/locale" -I. -I../../src -I../lib -I../../lib -D_FORTIFY_SOURCE=2 -Iyes/include -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -DNO_SSLv2 -D_FILE_OFFSET_BITS=64 -g -Wall Link: gcc -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Wformat-security -Werror=format-security -DNO_SSLv2 -D_FILE_OFFSET_BITS=64 -g -Wall -Wl,-Bsymbolic-functions -Wl,-z,relro -Lyes/lib -lssl -lcrypto -lz -ldl -lz -lidn -lrt ftp-opie.o openssl.o http-ntlm.o ../lib/libgnu.a
你:
Ubuntu 12.04.3 LTS 64 bit
我在我的家庭 LAN 上連接到 DHCP 路由器,連接到具有動態 IP 地址的 WAN 電纜調製解調器到住宅 ISP。