I am experiencing a problem where "lftp" will not recurse the remote tree while trying to do a mirror. The FTP server is an AS/400, client is debian linux, and lftp version 3.1.3. I have narrowed down the problem being attributed to the NLST output from the AS/400 appending a trailing slash "/" to directory names. I can reproduce the behaviour on a Solaris FTP server by adding 'set ftp:list-options "-F"' to my (otherwise operational) "solaris lvftp" script, thus causing it to break down in the same way.


Is this a bug, is there some workaround?

Thanks,
-Eddie


Here is my script:

 debug -o DEBUG 10
 open 1.2.3.4
 user xxxxxx yyyyyy
 site "na 1"
 cd /website
 lcd /root
 mirror -vvv dir test/
 quit



Here are the results:

[EMAIL PROTECTED]:~# find test -print
test
test/dir



Here is my debug:

[EMAIL PROTECTED]:~# cat DEBUG found netrc entry: host=1.2.3.4, user=xxxxxx, pass=yyyyyy, acct=
---- using user `xxxxxx' and password from ~/.netrc
---- Resolving host address...
---- 1 address found
found netrc entry: host=1.2.3.4, user=xxxxxx, pass=yyyyyy, acct=
dns cache hit
---- Connecting to 1.2.3.4 (1.2.3.4) port 21
<--- 220-QTCP at 1.2.3.4.
<--- 220 Connection will close if idle more than 5 minutes.
---> FEAT
<--- 211-Feature listing follows:
<--- AUTH TLS
<--- PBSZ
<--- PROT
<--- 211 End of feature listing.
---> USER xxxxxx
<--- 331 Enter password.
---> PASS yyyyyy
<--- 230 XXXXXXX logged on.
---> PWD
<--- 257 "QGPL" is current library.
---> SITE na 1
<--- 250 Now using naming format "1".
copy: get hit eof
copy: waiting for put confirmation
copy: put confirmed store
copy: get is finished - all done
---> CWD /website
<--- 250 "/website" is current directory.
---> CWD /website/dir
<--- 250 "/website/dir" is current directory.
---> PORT 10,1,7,47,141,169
<--- 200 PORT subcommand request successful.
---> LIST
<--- 125 List started.
---- Got EOF on data connection
---- Closing data socket
<--- 250 List completed.
---> PORT 10,1,7,47,141,170
<--- 200 PORT subcommand request successful.
---> NLST
<--- 125 List started.
---- Got EOF on data connection
---- Closing data socket
<--- 250 List completed.
---> QUIT
---- Closing control socket




Here is an AS/400 lftp session:

[EMAIL PROTECTED]:~# lftp 1.2.3.4
lftp [EMAIL PROTECTED]:~> cd /website
cd ok, cwd=/website lftp [EMAIL PROTECTED]:/website> dir
ASUSER 8192 04/26/05 13:54:16 *DIR dir/
ASUSER 8192 04/26/05 13:57:34 *DIR dir1/
ASUSER 365255 02/28/01 15:41:40 *STMF readme.txt
ASUSER 8489625 03/18/03 09:37:00 *STMF saved.zip
ASUSER 365255 02/28/01 15:41:40 *STMF unist.old
lftp [EMAIL PROTECTED]:/website> cls
readme.txt saved.zip unist.old lftp [EMAIL PROTECTED]:/website> quit




Here is an AS/400 ftp session:

 [EMAIL PROTECTED]:~# ftp 1.2.3.4
 Connected to 1.2.3.4.
 220-QTCP at 1.2.3.4.
 220 Connection will close if idle more than 5 minutes.
 331 Enter password.
 230 XXXXXX logged on.
 Remote system type is .
 ftp> na 1
 ?Invalid command
 ftp> site "na 1"
 250  Now using naming format "1".
 ftp> cd /website
 250 "/website" is current directory.
 ftp> nlist
 200 PORT subcommand request successful.
 125 List started.
 dir/
 dir1/
 data/
 readme.txt
 saved.zip
 unist.old
 250 List completed.
 ftp>



Here is a Solaris ftp session:

 [EMAIL PROTECTED]:~# ftp solaris
 Connected to solaris.
 220 solaris FTP server ready.
 331 Password required for xxxxxx.
 230 User xxxxxx logged in.
 Remote system type is UNIX.
 Using binary mode to transfer files.
 ftp> nlist
 200 PORT command successful.
 150 Opening ASCII mode data connection for file list.
 EDA_balance.tar.gz
 Initial_Crash_Dump_Analysis
 LDAP
 Maildir
 Sun_mtg__08.2603.doc
 tmp.123
 226 Transfer complete.
 ftp>







Reply via email to