command line - How to recursively download a folder via FTP on Linux -


i'm trying ftp folder using command line ftp client, far i've been able use 'get' individual files.

you rely on wget handles ftp (at least in own experience). example:

wget -r ftp://user:pass@server.com/ 

you can use -m suitable mirroring. equivalent -r -n -l inf.

if you've special characters in credential details, can specify --user , --password arguments work. example custom login specific characters:

wget -r --user="user@login" --password="pa$$wo|^d" ftp://server.com/ 

edit pointed out @asmaier, watch out if -r recursion, has default max level of 5:

       -r        --recursive            turn on recursive retrieving.         -l depth        --level=depth            specify recursion maximum depth level depth.  default maximum depth 5. 

if don't want miss out subdirs, better use mirroring option, -m:

       -m        --mirror            turn on options suitable mirroring.  option turns on recursion , time-stamping, sets infinite            recursion depth , keeps ftp directory listings.  equivalent -r -n -l inf            --no-remove-listing. 

Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -