Important Update: Archer Community Scheduled Maintenance on November 23–24 - New Community Launching Soon! Learn More..
2018-12-10 12:20 PM
Thought I'd ask my .net developers if they've seen an issue where FTP is not failing but not necessarily working 100%.
The scenario I have is that when sending a large file via FTP, the file, on occasion, will only send partially.
for example if the file size is 18 mb on the server, we're only seeing a 5mb file on the FTP with no errors (that I can see).
Using FIleStream to write the file...
Again, this doesn't happen consistently. So, I suspect network/connectivity issues, but don't understand why I'm not seeing an error when this happens. Seems to me my code should through an error.
Hoping you guys might have some ideas ---
2018-12-10 12:40 PM
I remember I had this issue with bigger files, like over 1Gb. But that because server did not accept more than 1Gb as a limit.
And server limit outage would not impose any Catch error, but with Java.
Similar I saw here: c# - Renci SSH.NET: SftpClient.UploadFile fails to upload files greater than 1GB in size - Stack Overflow
But for 18Mb, there should not be any issues
2018-12-10 01:50 PM
Thanks! I did see that article too.
But, as you said the file isn't nearly as big and since the file does transfer some times, I don't think it's a setting issue.
2018-12-11 02:06 AM
It might be the same cause as well, I mean when server closes connection, catch block does not trigger.
What I usually do, I use "finally" block from try-catch-finally triangle. There I check either file size between source and destination or checking hash. In case of any inconsistency, I just do reupload.
2019-01-22 12:17 PM
Done any work with private/public key authentication to a FTP using .net?
Having an issue with private key invalid exception.
I've seen plenty of different code snippets, but I suspect my issue is with how the key pair was generated.
Not an expert in this area, but again I suspect the issue is just with how the key was generated.
2019-01-22 12:23 PM
Nope, unfortunately never needed