We use Rebex FTP component to download files from FTP server. In our code we didn’t set the timeout property for connection.
I just wanted to know, what is the default timeout for a FTP connection. As I can see from the logs this connection is getting timed out after around 40 minutes. But I searched and the default timeout should be 60 seconds.
Could you please help me to increase this timeout period up to 1 hour?
Here is an excerpt from the log:
2013-03-18 15:37:17.670 INFO Ftp(1) Command: TYPE I
2013-03-18 15:37:17.763 INFO Ftp(1) Response: 200 Type set to I.
2013-03-18 15:37:17.779 INFO Ftp(1) Command: SIZE .
2013-03-18 15:37:17.888 INFO Ftp(1) Response: 550 .: not a plain file.
2013-03-18 15:37:17.888 INFO Ftp(1) Command: SIZE 'FILE NAME'
2013-03-18 15:37:18.013 INFO Ftp(1) Response: 213 1925070955
2013-03-18 15:37:18.028 DEBUG Ftp(1) Info: Starting data transfer.
2013-03-18 15:37:18.028 DEBUG Ftp(1) Info: Accepting data connection.
2013-03-18 15:37:18.044 INFO Ftp(1) Command: PORT 'PORT'
2013-03-18 15:37:18.340 INFO Ftp(1) Response: 200 PORT command successful.
2013-03-18 15:37:18.340 INFO Ftp(1) Command: RETR 'FILE NAME'
2013-03-18 15:37:18.558 INFO Ftp(1) Response: 150 Opening BINARY mode data connection for 'FILE NAME'
2013-03-18 15:37:18.589 DEBUG Ftp(1) Info: Data connection accepted from 'IP ADDRESS'
2013-03-18 16:17:01.225 INFO Ftp(1) Info: Timing out.
2013-03-18 16:17:01.225 ERROR Ftp(1) Info: Error while reading data: Rebex.Net.FtpException: Timeout exceeded.
at Rebex.Net.Ftp.QztfFZ()
at wWGvS.bEcmRk.BMJzdYZ(Byte[] , Int32 , Int32 )
at wWGvS.bEcmRk.Read(Byte[] buffer, Int32 offset, Int32 count)
2013-03-18 16:17:01.225 DEBUG Ftp(1) Info: Data connection failed.
2013-03-18 16:17:01.225 ERROR Ftp(1) Info: Rebex.Net.FtpException: Timeout exceeded.
at Rebex.Net.Ftp.QztfFZ()
at wWGvS.bEcmRk.BMJzdYZ(Byte[] , Int32 , Int32 )
at wWGvS.bEcmRk.Read(Byte[] buffer, Int32 offset, Int32 count)
at wWGvS.bsWOwAZ.Read(Byte[] buffer, Int32 offset, Int32 count)
at Rebex.Net.Ftp.bjMtzmZ(String , Boolean , Stream , Int64 , String )