Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
4.9k views
in .NET FTP by (160 points)
Can someone explain what might cause this error? Thanks in advance

DEBUG [FTPControlSocket] 4 May 2012 08:15:08.766 : ---> RETR MyFile.txt
DEBUG [FTPControlSocket] 4 May 2012 08:15:08.922 : 150 RETR command started
DEBUG [FTPConnection] 4 May 2012 08:15:08.922 : DownloadFile(D:\MyDir\MyFile.txt,MyFile.txt)
DEBUG [FTPControlSocket] 4 May 2012 08:15:08.938 : ---> PASV
DEBUG [FTPControlSocket] 4 May 2012 08:15:11.547 : 550 RETR failed: Could not create data connection.
INFO [FTPControlSocket] 4 May 2012 08:15:11.547 : Expected reply codes = [227] (strict=False)
ERROR [FTPClient] 4 May 2012 08:15:11.563 : Caught exception
ERROR [FTPClient] 4 May 2012 08:15:11.563 : EnterpriseDT.Net.Ftp.FTPException: RETR failed: Could not create data connection. (code=550)
ERROR [FTPClient] 4 May 2012 08:15:11.563 : at EnterpriseDT.Net.Ftp.FTPControlSocket.ValidateReply(FTPReply reply, String[] expectedReplyCodes)
ERROR [FTPClient] 4 May 2012 08:15:11.563 : at EnterpriseDT.Net.Ftp.FTPControlSocket.CreateDataSocketPASV()
ERROR [FTPClient] 4 May 2012 08:15:11.563 : at EnterpriseDT.Net.Ftp.FTPClient.InitGet(String remoteFile)
ERROR [FTPClient] 4 May 2012 08:15:11.563 : at EnterpriseDT.Net.Ftp.FTPClient.GetBinary(String localPath, String remoteFile)
DEBUG [FTPConnection] 4 May 2012 08:15:11.579 : Closing connection (instance=0)
DEBUG [FTPFileFactory] 4 May 2012 08:15:11.579 : Defaulting to Unix parsing
DEBUG [FTPControlSocket] 4 May 2012 08:15:11.594 : ---> QUIT

3 Answers

0 votes
by (162k points)
This is causing the problem:

DEBUG [FTPControlSocket] 4 May 2012 08:15:08.766 : ---> RETR MyFile.txt

How is the RETR getting there? It should be *after* PASV.
0 votes
by (160 points)
Thanks for the quick response. We actually fixed it.
It seemed we got this error if we tried to download any file after a failed call to FTPConnection.Exists(). For some reason (on this particular server) this returned an error if the file actually didn't exist, and after that it couldn't download.
0 votes
by (162k points)
Ok that explains it. Thanks for following up.

Categories

...