I'm using FFS 11.11 (Donation Version) mostly with a Linux server. The server limits the number of parallel ftp user to 10.
Therefore I use a FFS ftp user limit of 8 (to allow an additional FileZilla session).
If I start a synchronisation of a configuration and shortly after that (1st one is finished) a synchronisation of another configuration (same server), I get the error shown in the attachment. I assume that the re-use of ftp sessions over multiple configurations is broken.
Error too much ftp user
- Posts: 49
- Joined: 7 Nov 2020
- Attachments
-
- ffs_ftp_user.jpg (20.12 KiB) Viewed 6115 times
- Site Admin
- Posts: 7211
- Joined: 9 Dec 2007
FFS should behave according to these rules: https://freefilesync.org/manual.php?topic=performance
PS: You can check the number of TCP connections with Process Explorer.
PS: You can check the number of TCP connections with Process Explorer.
- Posts: 49
- Joined: 7 Nov 2020
I already follow the above rules. The error does not occur if I quit FFS between the two runs. If I run the two configurations after another, the ftp connections of the 1st run are obviously not re-used and therefore the ftp server says too many connections.
- Posts: 49
- Joined: 7 Nov 2020
This is from tcpview. FFS creates 10 connections (and tries more) even that I configured 8 for each configuration. And no, I do not run them in parallel.
- Attachments
-
- ffs_ftp_user_2.jpg (75.94 KiB) Viewed 6101 times
- Posts: 49
- Joined: 7 Nov 2020
Any news about this error? Can you (Zenju) confirm it?
- Posts: 49
- Joined: 7 Nov 2020
Very sad that there are no more replies.... 😕
- Posts: 4056
- Joined: 11 Jun 2019
Give him some time, for all you know he may have fixed it already. He doesn't usually update anyone on progress, but usually just posts a version with a fix. He is great
- Posts: 49
- Joined: 7 Nov 2020
:-) Ok, I sit back and wait.... I assume that FFS in general still has some problems with ftp. This problem is still unsolved. Because of this I cannot use TLS for syncing my remote server. I just tried it again. Still same error. Without TLS it works. FileZilla has no problems at all. But FFS is just much better/easier in syncing as FZ.
- Attachments
-
- ftp.jpg (35.68 KiB) Viewed 4341 times
- Site Admin
- Posts: 7211
- Joined: 9 Dec 2007
libcurl (= what FreeFileSync uses for the FTP access) internally uses *two* TCP connections:
https://everything.curl.dev/usingcurl/ftp/twoconnections
What you set up in FFS as "Parallel file operations" controls the number of curl handles each of which is a pair of TCP connections:
- one (permanent) control connection that is kept open after each FTP command.
- one (short-lived) data connection that is opened and closed for each file upload / download or folder traversal.
So, if your FTP server only counts control connections, then #"Parallel file operations" can be set as high as the server allows for number of connected users.
Maybe your FTP server counts both data and control connections? This could explain the symptoms, but is probably a counting issue on the server side. In this case you need to set "Parallel file operations" in FFS to half of what the server limit is, e.g. in the above case 10 / 2 = 5.
I believe your screenshot above shows 8 control connections and 2 data connections. In this case, FFS should only consume 8 of the 10 user slots that the server allows.
https://everything.curl.dev/usingcurl/ftp/twoconnections
What you set up in FFS as "Parallel file operations" controls the number of curl handles each of which is a pair of TCP connections:
- one (permanent) control connection that is kept open after each FTP command.
- one (short-lived) data connection that is opened and closed for each file upload / download or folder traversal.
So, if your FTP server only counts control connections, then #"Parallel file operations" can be set as high as the server allows for number of connected users.
Maybe your FTP server counts both data and control connections? This could explain the symptoms, but is probably a counting issue on the server side. In this case you need to set "Parallel file operations" in FFS to half of what the server limit is, e.g. in the above case 10 / 2 = 5.
I believe your screenshot above shows 8 control connections and 2 data connections. In this case, FFS should only consume 8 of the 10 user slots that the server allows.
- Posts: 49
- Joined: 7 Nov 2020
The server (shared hosting service [of course not under my control] with ProFTPD and parameter MaxClientsPerUser = 10) counts correct.
If I set one FFS config to 10 parallel connections and only run this, it works. If I set one config to 11 and only run this, it - of course - fails.
If I set my 2 configs each to 5 parallel operations and do first a compare for config 1 and only once this is finished a compare of config 2, it works.
But, FFS creates 10 ftp connections on this two consecutive runs! I can see those 10 connections in Sysinternals tcpview64.exe. That means that the 5 connections of config 1 are neither closed once compare 1 is finished nor reused for compare 2. Therefore I get the error if I set both configs to 8 parallel connections each.
I'm still sure a problem in FFS causes this error!
If I set one FFS config to 10 parallel connections and only run this, it works. If I set one config to 11 and only run this, it - of course - fails.
If I set my 2 configs each to 5 parallel operations and do first a compare for config 1 and only once this is finished a compare of config 2, it works.
But, FFS creates 10 ftp connections on this two consecutive runs! I can see those 10 connections in Sysinternals tcpview64.exe. That means that the 5 connections of config 1 are neither closed once compare 1 is finished nor reused for compare 2. Therefore I get the error if I set both configs to 8 parallel connections each.
I'm still sure a problem in FFS causes this error!
- Site Admin
- Posts: 7211
- Joined: 9 Dec 2007
If FFS isn't reusing the connections, it must be because it considers them to be "different". Maybe for one sync config you have set encryption to "disabled" and for the other config encryption is set to "Explicit TLS". This would be one case where FFS doesn't consider connections for reuse due to different settings.But, FFS creates 10 ftp connections on this two consecutive runs! I can see those 10 connections in Sysinternals tcpview64.exe. That means that the 5 connections of config 1 are neither closed once compare 1 is finished nor reused for compare 2. Therefore I get the error if I set both configs to 8 parallel connections each. mdrmdr, 01 Jul 2021, 11:14
- Posts: 49
- Joined: 7 Nov 2020
Mea culpa! I indeed had TLS disabled for config 1 (because of this still open problem) and still enabled for config 2. Disabling TLS for both configs now does not show anymore the max. number of ftp connections error.
Maybe it's worth to add this restriction (connection re-use only if identical ftp setup; otherwise risk to exceed allowed number of connections if ftp server limits connections) to the ftp documentation. Most shared hoster do limit connections...
Thanks a lot for the tip to the solution.
Maybe it's worth to add this restriction (connection re-use only if identical ftp setup; otherwise risk to exceed allowed number of connections if ftp server limits connections) to the ftp documentation. Most shared hoster do limit connections...
Thanks a lot for the tip to the solution.
- Site Admin
- Posts: 7211
- Joined: 9 Dec 2007
Fixed! No need for documentation.
FreeFileSync 12.0
-----------------
Avoid hitting (S)FTP connection limit for non-uniform configs