Yet another .KeepAlive question

When I'm uploading files to an FTP server running Unix (which I don't have any control over) I repeatedly get:

System.Net.WebException: The remote server returned an error: (500) Syntax error, command unrecognized.
at System.Net.FtpWebRequest.SyncRequestCallback(Object obj)
at System.Net.FtpWebRequest.RequestCallback(Object obj)
at System.Net.CommandStream.Abort(Exception e)
at System.Net.FtpWebRequest.FinishRequestStage(RequestStage stage)
at System.Net.FtpWebRequest.GetRequestStream()

This happens slightly more often than once in a minute. I eventually *do* get all files through since I have extensive error recovery, but it is very annoying and also degrades performance.

Now we have tracked down the "unrecognized" command to be "USER ...", which apparently the .NET FTP Lib sends while still being logged in!

For some reason the FTP Lib seems to think that the connection is not alive anymore, while the FTP server think it is. Any ideas what I can do to solve this issue

Thnx,
Dan




Answer this question

Yet another .KeepAlive question