Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
4.7k views
in .NET FTP by (200 points)
Hello,

I am using the edtFTPnet version 2.0.1 to connect to a ftp server running under zOS on an IBM mainframe. zOS has some quirky naming rules, one of which being that each qualifier of the name (qualifier1.qualifier2.qualifier3), can have a max of 8 characters.

When I try to list something with more than 8 characters, I end up getting an IOException instead of a error message from the server of some sort. Which is kinda weird because I am getting a 501 message back from the server and it seems like edtFTP is not dealing with that message and continuing to wait for data from the server.

[ 2009-11-06 13:56:01,058 ] INFO  Ftp Connection: Connected to zsystem10
[ 2009-11-06 13:56:01,058 ] INFO  Ftp Connection: Logging into zsystem10 as frank
[ 2009-11-06 13:56:01,058 ] DEBUG ---> USER frank
[ 2009-11-06 13:56:01,120 ] DEBUG 331 Send password please.
[ 2009-11-06 13:56:01,120 ] DEBUG ---> PASS ********
[ 2009-11-06 13:56:01,493 ] DEBUG 230 FRANK is logged on.  Working directory is "FRANK.".
[ 2009-11-06 13:56:01,493 ] INFO  Ftp Connection: frank logged in.
[ 2009-11-06 13:56:01,493 ] DEBUG ---> SYST
[ 2009-11-06 13:56:01,555 ] DEBUG 215 MVS is the operating system of this server. FTP Server is running on z/OS.
[ 2009-11-06 13:56:01,555 ] INFO  Connection to zsystem10 established.
[ 2009-11-06 13:56:01,555 ] DEBUG bw_list: ConnectMe_Complete
[ 2009-11-06 13:56:01,555 ] INFO  Ftp Connection: Retrieving "*"
[ 2009-11-06 13:56:01,555 ] DEBUG ---> NOOP
[ 2009-11-06 13:56:01,618 ] DEBUG 200 OK
[ 2009-11-06 13:56:01,618 ] INFO  Ftp Connection: Listing Reports...
[ 2009-11-06 13:56:03,172 ] DEBUG ---> SYST
[ 2009-11-06 13:56:03,219 ] DEBUG 215 MVS is the operating system of this server. FTP Server is running on z/OS.
[ 2009-11-06 13:56:03,234 ] DEBUG ---> PWD
[ 2009-11-06 13:56:03,281 ] DEBUG 257 "'FRANK.'" is working directory.
[ 2009-11-06 13:56:03,296 ] DEBUG ---> PASV
[ 2009-11-06 13:56:03,343 ] DEBUG 227 Entering Passive Mode (172,29,122,64,4,9)
[ 2009-11-06 13:56:03,405 ] DEBUG ---> LIST abdskeinms*
[ 2009-11-06 13:56:03,467 ] DEBUG 501 Qualifier too long.  Use MVS naming conventions.
[ 2009-11-06 13:56:18,234 ] DEBUG FileList:ListMe -> IOException
[ 2009-11-06 13:56:18,250 ] FATAL Ftp Report Listing Failed : Report listing failed.
[ 2009-11-06 13:56:18,250 ] INFO  Unable to read data from the transport connection: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.



Any idea what is going on?
Thanks

4 Answers

0 votes
by (162k points)
You should get an FTPException - post the stack trace for the exception and we'll be able to tell you what's happening.
0 votes
by (200 points)
stack trace from the IOException

at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
   at System.IO.BufferedStream.ReadByte()
   at EnterpriseDT.Net.Ftp.FTPClient.ReadASCIIListingData(String dirname)
   at EnterpriseDT.Net.Ftp.FTPClient.Dir(String dirname, Boolean full)
   at EnterpriseDT.Net.Ftp.FTPClient.DirDetails(String dirname)
   at EnterpriseDT.Net.Ftp.FTPConnection.GetFileInfos(String directory)
   at zXPF_PC.ListReportFromMainframe.ListMe(Object sender, DoWorkEventArgs e) in C:\Documents and Settings\tabo\My Documents\Visual Studio 2008\Projects\zXPF PC\zXPF UI\ListReportFromMainframe.cs:line 1064
0 votes
by (162k points)
If you set StrictReturnCodes = true you'll get the correct exception.
0 votes
by (200 points)
Thanks. That worked!

Categories

...