-
-
Notifications
You must be signed in to change notification settings - Fork 657
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sporadic reproducible GetListing, Download and other failures: IOException on control connection #1030
Comments
This is the original post of @oleksabor, many thanks to him for this effort: Original post from #104I did a test (like stress test) that connects to the FTPs server and download files. The test is executed in a loop, about 170 iterations. One iteration is to
170 iterations, 3 folders, 2 files in each folder. I've tried the FileZilla ftp server (both IIS ftpsI've used the https://medium.com/@sithum/create-ftps-server-on-windows-server-iis-in-5-minutes-sithum-devops-7a09823d91a4 guide to set up ftps with IIS The problem is that I'm getting error each 25 time - I can run test project three times in a row and three times it produces the same errors
The same (approximately) errors are thrown each time I'm running this test
FileZillaI've just installed FileZilla server and added a test user with the FileZilla server
There are less errors on FileZilla with 500ms pauses between each ftp call but
here are logs
I did those tests on my Windows 10 OS version 20H2 OS build 19042, 1288) test project uses the .Net Framework 4.8 and FluentFtp 35.0.5 Connection is FTPS w/ Explicit mode I've tried to add some |
I then wrote, in #104 @oleksabor Using your exact github code and connecting to a very high performace proftpd server of my own, I can reproduce the issue. I am getting the same errors ( your sln is using FluentFTP V35).After upgrading to FluentFTP V42 and making the few neccessary ->V40 migration changes, the problem STILL can be reproduced. So now we can start to search for the problem. |
Some first results of testing, using @oleksabor initial approach as a basis. I forked his GitHub test sln. The goal was to find out a little bit more about the real problem and to remove conjecture.
These commands do not use a data connection. No data connection (SSL) needs to be created and disposed. They only exercise the control connection. These commands are iterated up to 500 times with no waits in between. They always fail in the same way on the 474th iteration, on all of my available client systems.
|
I have further reduced the tests to
I can do 1057 of these commands and then I get the above described failure. Choosing a "longer" command (i.e. more bytes) does not change the number of commands before the exception occurs. So I my environment I can cycle about 1057 commands/responses and then I get an IOException. |
Conversely, if I do
Guess how many? 289. |
Made a small change to only honor If that was not your intention, I can change the behavior, let me know. |
This is now released as V42.1.0 |
This has been reported quite a few times.
What does the failure look like?
Typically, it manifests as an
IOException
. Depending on the API call being performed, this exception can causeGetListing
result to be empty while the exeption is ignoredIOException
.If you look closely at the
IOException
, you might see:an attempt was made to access a socket in a way forbidden by its access permissions
When does it happen?
It happens on an control connection (only if encrypted) when you have issued many API calls (that execute commands and get the response).
Reported by (ignore the incorrect title):
@omanThYp #104 (comment)
@oleksabor #104 (comment)
#752 could such a case, but sadly there is no log
See also #723 : one of the "strange" ways this problem can show up.
A newer issue of this kind: #1130
The text was updated successfully, but these errors were encountered: