我正在尝试从类似这样的目录结构中仅下载 .nc 文件:
+ podaac-tools.jpl.nasa.gov/drive/files/allData/ghrsst/data/GDS2/L4/GLOB/JPL/MUR/v4.1/2020/
+ 001
+ 001-MUR-GLOB-v02.0-fv04.1.nc
+ 001-MUR-GLOB-v02.0-fv04.1.nc.md5
+ 002
+ 002-MUR-GLOB-v02.0-fv04.1.nc
+ 002-MUR-GLOB-v02.0-fv04.1.nc.md5
+ 003
+ 003-MUR-GLOB-v02.0-fv04.1.nc
+ 003-MUR-GLOB-v02.0-fv04.1.nc.md5
+ 004
+ 004-MUR-GLOB-v02.0-fv04.1.nc
+ 004-MUR-GLOB-v02.0-fv04.1.nc.md5
我在用着:
wget -r -nd -nc -A "*.nc" https://podaac-tools.jpl.nasa.gov/drive/files/allData/ghrsst/data/GDS2/L4/GLOB/JPL/MUR/v4.1/2020/
每当我使用-A "*.nc"
或-A.nc
标志时,命令都会被拒绝:
--2020-03-30 18:20:29-- https://podaac-
tools.jpl.nasa.gov/drive/files/allData/ghrsst/data/GDS2/L4/GLOB/JPL/MUR/v4.1/2020/
Resolving podaac-tools.jpl.nasa.gov (podaac-tools.jpl.nasa.gov)... 137.78.248.120
Connecting to podaac-tools.jpl.nasa.gov (podaac-tools.jpl.nasa.gov)|137.78.248.120|:443... connected.
HTTP request sent, awaiting response... 401 Unauthorized
Authentication selected: Basic realm="PODAAC_Drive"
Reusing existing connection to podaac-tools.jpl.nasa.gov:443.
HTTP request sent, awaiting response... 200 OK
Length: 48529 (47K) [text/html]
Saving to: ‘index.html.tmp’
index.html.tmp 100%[===================>] 47.39K --.-KB/s in 0.1s
2020-03-30 18:20:30 (492 KB/s) - ‘index.html.tmp’ saved [48529/48529]
Removing index.html.tmp since it should be rejected.
FINISHED --2020-03-30 18:20:30--
Total wall clock time: 1.4s
Downloaded: 1 files, 47K in 0.1s (492 KB/s)
否则,如果我不使用-A "*.nc"
或-A.nc
标志,我就会下载包含目录中的所有文件,这比我想要的还多。
答案1
-R = --reject
可能会有帮助。
尝试:
wget -r -nd -nc -R="*.md5" https://podaac-tools.jpl.nasa.gov/drive/files/allData/ghrsst/data/GDS2/L4/GLOB/JPL/MUR/v4.1/2020/