Hello,
I do the following (quite vanilla I think)
Sftp ftp = new Sftp();
ftp.Timeout = 30000;
ftp.Settings.UseLargeBuffers = true;
ftp.Settings.SshParameters.PreferredHostKeyAlgorithm = SshHostKeyAlgorithm.ECDsaNistP521;
ftp.Connect(server, Sftp.DefaultPort);
ftp.Login(username, password);
ftp.Download( "tenfiles*.csv" , templocalfolder , TraversalMode.MatchFilesShallow);
ftp.Disconnect();
With rebex sftp class I am uploading a 1.5Gbyte file every morning and I am downloading roundabout 10 to 15 files every evening (filesizes 400 to 800kbyte).
Version of rebex class is 5.0.70270.0 from Nov 2019.
It is running on Windows Server 2016 with every security updates in place.
This was running very smooth and healthy in the last 18 month.
With only one reboot per month (when I had to install the security updates).
Since November security update (I think this is the cause) this works for 6 days.
After 6 days I get the following error:
See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
Rebex.Net.SftpException: The operation was not completed within the specified time limit. ---> Rebex.Net.SshException: The operation was not completed within the specified time limit.
at Rebex.Net.SshSession.yfpe[a,b](ioix2 aff, Int32 afg, ioiy afh, b afi, a afj, a afk)
at Rebex.Net.SshSession.yfpd[a,b](ioix
2 afd, b afe)
at Rebex.Net.SshChannel.bnkb[a,b](ioix`2 wr, b ws)
at Rebex.Net.SshChannel.Receive(Byte[] buffer, Int32 offset, Int32 count)
at bsdk.ocjc(Byte[] m, Int32 n, Int32 o)
at bsdz.lctu(Int32 arq)
at bsdz.lctw(rhth& art)
at bsdz.lctt(UInt32 aro, Boolean arp)
at bsdz.lcsv(UInt32 aon, bsdj aoo)
at Rebex.Net.Sftp.wnav(bsdj sb, String sc, Stream sd, Int64 se, Int64 sf, rhua sg)
--- End of inner exception stack trace ---
at Rebex.Net.Sftp.wnav(bsdj sb, String sc, Stream sd, Int64 se, Int64 sf, rhua sg)
at Rebex.Net.Sftp.wnat(FileMode ro, bsdj rp, String rq, String rr, Int64 rs, Int64 rt, Int64 ru, rhua rv)
at bsdu.rllx(FileMode amw, String amx, String amy, Int64 amz, Int64 ana)
at bsdu.rdgr(rhtu bev, rhtu bew, String bex, String bey, Boolean bez)
at rhtx.rdfn(String ece, String ecf, rhtu ecg, rhtu ech, rhtu eci, rhtu ecj, Boolean eck, Boolean ecl, Boolean ecm)
at rhtx.rdfm(rhtv ecd)
at rhtx.rdfj()
at rhtx.rdfe(TransferAction ebo, rhtt ebp, String ebq, TransferMethod ebr, MoveMode ebs, LinkProcessingMode ebt, ActionOnExistingFiles ebu, rhtu ebv)
at Rebex.Net.Sftp.wnbt(TransferAction ut, bsdj uu, bsdt uv, String uw, TransferMethod ux, MoveMode uy, LinkProcessingMode uz, ActionOnExistingFiles va)
at Rebex.Net.Sftp.Download(String remotePath, String localDirectoryPath, TraversalMode traversalMode, TransferMethod transferMethod, ActionOnExistingFiles existingFileMode)
at MyStuff.ReportingHelper.GrabReportingFromServer()
at MyStuff.ReportingHelper.ProcessReporting(DateTime pdt, Int32 ptransactionnumber)
************** Loaded Assemblies **************
mscorlib
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3890.0 built by: NET472REL1LAST_B
CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
System.Windows.Forms
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3835.0 built by: NET472REL1LAST_B
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GACMSIL/System.Windows.Forms/v4.04.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
System
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3650.0 built by: NET472REL1LAST_B
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GACMSIL/System/v4.04.0.0.0__b77a5c561934e089/System.dll
System.Drawing
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3062.0 built by: NET472REL1
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GACMSIL/System.Drawing/v4.04.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
System.Configuration
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3630.0 built by: NET472REL1LAST_B
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GACMSIL/System.Configuration/v4.04.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
System.Xml
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3062.0 built by: NET472REL1
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GACMSIL/System.Xml/v4.04.0.0.0__b77a5c561934e089/System.Xml.dll
Accessibility
Assembly Version: 4.0.0.0
Win32 Version: 4.7.3062.0 built by: NET472REL1
CodeBase: file:///C:/Windows/Microsoft.Net/assembly/GACMSIL/Accessibility/v4.04.0.0.0__b03f5f7f11d50a3a/Accessibility.dll
When I start my exe after this error and only want to download 10 files it is very slow.
After a reboot of this machine I have normal speeds for one week.
After one week of operation it starts again with a very slow download speed (until it didn't work because of timeouts).
I can buy a new license of rebex - this is not a problem.
I want back the rock solid operation from two month ago (please, this makes me gray hairs).
Best regards,
Thomas