Have you tried $ftp->ls() without the UNIX-specific parameters "-Al"?
$ftp->ls expects a directory as the argument, or when empty, will list current directory. That you can use command line swithes could be called a bug, or a feature, depending on who you ask. :) Point is, that the UNIX ftp server either asks the shell for ls "whatever you said", or is aware of such switches. (That is, of course, assuming that you have those switches for a reason, and that they produce different results?) Serv-U most likely isn't, although you could, for fun, try to enter Windows/DOS-specific switches and see what happens.
You have moved into a dark place.
It is pitch black. You are likely to be eaten by a grue. | [reply] [d/l] [select] |
GG,
besides the excellent suggestion by Dog and Pony, you should
consider if you need to use "passive" mode ftp. If there's a firewall
between your client and your FTP Server, there may be some
rules which disallow the FTP Server from opening the data connection
and sending data. Hence the need for passive mode. Do you run the
same script on a Unix Server to the NT FTP server or the same script
on the same client to a UNIX FTP server? If it's the former (Unix to
NT FTP server), the FTP_PASSIVE environment variable may be
set in which case Net::FTP will work appropriately. You don't
show the code but is the ls not returning anything or failing? Most
passive ftp problems will show up as a long lag time when trying
to retrieve from or list on the FTP server. Appropriate error checking
should point you in the right direction.
-derby | [reply] |