Page 1 of 1

vsftpd Connection refused: too many sessions for this address

Posted: Sat Jun 02, 2018 8:29 am
by prxbl
I am using latest version of vesta 0.9.8r21 on ubuntu 14.04 and vsftpd: version 3.0.2 and my problem is related to uploading files via FTP.
The service has worked great for the past two years and I was able to upload thousands of files with 0 errors. However recently,
I can't do that anymore, if I try to upload let's say 1000 files, it will do the first ~300 files ok but then it will start to fail
until gradually all upload slots are blocked retrying on these failed files 2 times, waiting for the timeout, and in the end I am left with a bunch of failed transfers.
I am using Filezilla 3.33 on Windows as a client. This is what it looks like in Filezilla when it initially fails:

Code: Select all

Status:	Starting upload of C:\wamp64\www\system\themes\widget\html.php
Status:	Retrieving directory listing of "/web/domain.com/public_html/system/themes/widget"...
Command:	PASV
Response:	227 Entering Passive Mode (10,10,20,10,50,217).
Command:	STOR icon_box.php
Response:	150 Ok to send data.
Error:	Connection timed out after 10 seconds of inactivity
Error:	File transfer failed
vsftp.log looks like this for the failed transfers:

Code: Select all

Sat Jun  2 10:17:00 2018 [pid 29163] [admin] FAIL UPLOAD: Client "ip", "/web/domain.com/public_html/system/themes/widget/html.php", 853 bytes, 0.00Kbyte/sec
Then after some retries Filezilla shows these errors:

Code: Select all

Response:	421 There are too many connections from your internet address.
Error:	Could not connect to server
Status:	Disconnected from server
Status:	Delaying connection for 5 seconds due to previously failed connection attempt...
Response:	421 There are too many connections from your internet address.
Error:	Could not connect to server
Response:	421 There are too many connections from your internet address.
Error:	Could not connect to server
vsftp.log looks like this:

Code: Select all

Sat Jun  2 11:20:19 2018 [pid 3616] CONNECT: Client "ip", "Connection refused: too many sessions for this address."
Sat Jun  2 11:20:24 2018 [pid 3622] CONNECT: Client "ip", "Connection refused: too many sessions for this address."
Sat Jun  2 11:20:24 2018 [pid 3632] CONNECT: Client "ip", "Connection refused: too many sessions for this address."
This is how my config looks for vsftpd:

Code: Select all

anonymous_enable=NO
local_enable=YES
write_enable=YES
local_umask=002
anon_upload_enable=NO
dirmessage_enable=YES
xferlog_enable=YES
dual_log_enable=YES
connect_from_port_20=YES
xferlog_std_format=YES
chroot_local_user=YES
listen=YES
pam_service_name=vsftpd
userlist_enable=NO
tcp_wrappers=YES
force_dot_files=YES
ascii_upload_enable=YES
ascii_download_enable=YES
#allow_writable_chroot=YES
allow_writeable_chroot=YES
seccomp_sandbox=NO
pasv_enable=YES
pasv_max_port=14000
pasv_min_port=12000
Any ideas on how this can be fixed? Thank you!

Re: vsftpd Connection refused: too many sessions for this address

Posted: Sun Jun 21, 2020 11:42 am
by dioxide
has anybody found any solution to this

Re: vsftpd Connection refused: too many sessions for this address

Posted: Mon Jun 22, 2020 8:59 pm
by peters
I think that there will be no fix as the project seems to be death. However to me it sounds like a firewall issue (port range blocked or some kind of connection flooding if you run csf connlimit setting)