为什么 wget -r 不获取所有 FTP 子目录?

dub*_*bis 7 ftp wget

当我执行命令时:

 wget -r ftp://user:paswword@ftp.xxxx.ovh.net/
Run Code Online (Sandbox Code Playgroud)

它缺少任何子子目录。递归FTP有限制吗?

Mik*_*kel 9

你的深度是多少?如果需要 5 个以上,则需要提供-l选项。

男人 wget

-r
--recursive
    Turn on recursive retrieving.    The default maximum depth is 5.

-l depth
--level=depth
    Specify recursion maximum depth level depth.
-m
--mirror 
Turn on options suitable for mirroring. 
This option turns on recursion and time-stamping, 
sets infinite recursion depth and keeps FTP directory listings. 
It is currently equivalent to ‘-r -N -l inf --no-remove-listing’.
Run Code Online (Sandbox Code Playgroud)


dub*_*bis 6

wget 的 -m 选项是无限递归

-m
--mirror 
Turn on options suitable for mirroring. 
   This option turns on recursion and time-stamping, 
   sets infinite recursion depth and keeps FTP directory listings. 
   It is currently equivalent to ‘-r -N -l inf --no-remove-listing’.
Run Code Online (Sandbox Code Playgroud)

谢谢你的帮助。