FTP Backup Issue v20 update 7

Derek99

Silver Partner
Joined
Oct 20, 2025
Messages
1
Reaction score
0
We've been using an external FTP server for our 3CX backups up until recently without any issues.
However since the v20 update 7 I've started to get error messages whenever the automatic backup runs.
We are using the ftpes:// server option which is uploading to an external FileZilla server.
We are getting the same error message on multiple 3CX servers that we run.

The error message I am getting is:

SeverityError
Event ID50022
Date10/19/2025 11:55 PM
DetailsYour 3CX backup failed due to the following reason(s): System.Exception: Cannot upload data to FTP. required size = 1262064614. realsize = 1262023718 at _3CX.Filesystem.FTP.FtpWrapperStream.Close() at System.IO.Compression.ZipArchive.CloseStreams() at System.IO.Compression.ZipArchive.Dispose(Boolean disposing) at System.IO.Compression.ZipArchive.Dispose() at _3CX.BackupRestore._3cxBackup.Tasks_Finished(Object sender, EventArgs e)

When I check on the FTP server I can see that the file was uploaded and is the correct required size (1 262 064 614 bytes).
1760941374743.png

However in the error message 3CX thinks the size was 1 262 023 718 bytes.

In my FTP server logs I can see the file finishes successfully uploading at 23:55:37 PM.

For some strange reason, the 3CX server checks the size of the file 11 times between 23:55:20 PM and 23:55:31 PM before the upload has finished.
The 11th time it checks the size, it is 1 262 023 718 bytes which is the same value as the realsize in the error message above.
It's the wrong size, because the file hasn't finished uploading when it's getting checked.
The 3CX server then stops checking the size and then tries to delete the file, while it's still uploading, so it fails to delete.

It looks like something has changed in the way 3CX is transferring the backup file, which is causing it to prematurely check the file size before the upload finishes.


(003918) 19/10/2025 23:50:07 PM - username (<3CX_Server_IP>)> 229 Entering Extended Passive Mode (|||61881|)
(003918) 19/10/2025 23:50:07 PM - username (<3CX_Server_IP>)> STOR /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:50:07 PM - username (<3CX_Server_IP>)> 150 Opening data channel for file upload to server of "/ICT-3CX/3CXScheduledBackup.zip.tmp"
(003918) 19/10/2025 23:50:07 PM - username (<3CX_Server_IP>)> TLS connection for data connection established
(003918) 19/10/2025 23:55:20 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:20 PM - username (<3CX_Server_IP>)> 213 1261953269
(003918) 19/10/2025 23:55:21 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:21 PM - username (<3CX_Server_IP>)> 213 1261958640
(003918) 19/10/2025 23:55:22 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:22 PM - username (<3CX_Server_IP>)> 213 1261965965
(003918) 19/10/2025 23:55:23 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:23 PM - username (<3CX_Server_IP>)> 213 1261973353
(003918) 19/10/2025 23:55:24 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:24 PM - username (<3CX_Server_IP>)> 213 1261980776
(003918) 19/10/2025 23:55:26 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:26 PM - username (<3CX_Server_IP>)> 213 1261988120
(003918) 19/10/2025 23:55:27 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:27 PM - username (<3CX_Server_IP>)> 213 1261995521
(003918) 19/10/2025 23:55:28 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:28 PM - username (<3CX_Server_IP>)> 213 1262002593
(003918) 19/10/2025 23:55:29 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:29 PM - username (<3CX_Server_IP>)> 213 1262009575
(003918) 19/10/2025 23:55:30 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:30 PM - username (<3CX_Server_IP>)> 213 1262016676
(003918) 19/10/2025 23:55:31 PM - username (<3CX_Server_IP>)> SIZE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003918) 19/10/2025 23:55:31 PM - username (<3CX_Server_IP>)> 213 1262023718
(003965) 19/10/2025 23:55:31 PM - (not logged in) (<3CX_Server_IP>)> Connected on port 21, sending welcome message...
(003965) 19/10/2025 23:55:31 PM - (not logged in) (<3CX_Server_IP>)> 220-FileZilla Server 0.9.60 beta
(003965) 19/10/2025 23:55:31 PM - (not logged in) (<3CX_Server_IP>)> 220-written by Tim Kosse ([email protected])
(003965) 19/10/2025 23:55:31 PM - (not logged in) (<3CX_Server_IP>)> 220 Please visit https://filezilla-project.org/
(003965) 19/10/2025 23:55:31 PM - (not logged in) (<3CX_Server_IP>)> AUTH TLS
(003965) 19/10/2025 23:55:31 PM - (not logged in) (<3CX_Server_IP>)> 234 Using authentication type TLS
(003965) 19/10/2025 23:55:31 PM - (not logged in) (<3CX_Server_IP>)> TLS connection established
(003965) 19/10/2025 23:55:32 PM - (not logged in) (<3CX_Server_IP>)> USER username
(003965) 19/10/2025 23:55:32 PM - (not logged in) (<3CX_Server_IP>)> 331 Password required for username
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 230 Logged on
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> PBSZ 0
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 200 PBSZ=0
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> PROT P
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 200 Protection level set to P
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> FEAT
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 211-Features:
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> MDTM
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> REST STREAM
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> SIZE
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> MLST type*;size*;modify*;
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> MLSD
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> AUTH SSL
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> AUTH TLS
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> PROT
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> PBSZ
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> UTF8
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> CLNT
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> MFMT
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> EPSV
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> EPRT
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 211 End
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> OPTS UTF8 ON
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 202 UTF8 mode is always enabled. No need to send this command.
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> SYST
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 215 UNIX emulated by FileZilla
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> PWD
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 257 "/" is current directory.
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> DELE /ICT-3CX/3CXScheduledBackup.zip.tmp
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 500 Failed to delete the file.
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> QUIT
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> 221 Goodbye
(003965) 19/10/2025 23:55:32 PM - username (<3CX_Server_IP>)> disconnected.
(003918) 19/10/2025 23:55:37 PM - username (<3CX_Server_IP>)> 226 Successfully transferred "/ICT-3CX/3CXScheduledBackup.zip.tmp"
(003918) 19/10/2025 23:57:38 PM - username (<3CX_Server_IP>)> 421 Connection timed out.
(003918) 19/10/2025 23:57:38 PM - username (<3CX_Server_IP>)> disconnected.
 
Hello,

I would suggest opening a ticket with support to look into this.

Best,
KS
 
If direct upload fails, try adding ALWAYS_USE_TMP_FILE_FOR_BACKUP in Advanced > Parameters with value 1
 
  • Like
Reactions: fxbastler
Same situation here since U7. We filed a ticket to Italian support.
 
  • Like
Reactions: MaximeDufour
If direct upload fails, try adding ALWAYS_USE_TMP_FILE_FOR_BACKUP in Advanced > Parameters with value 1
This way it works with no error. How can i do that on all 527 systems we manage? Why this happens? Since v.15.5 it always worked the same, it only started after V20 U7...
 
  • Like
Reactions: MaximeDufour
Same situation here since U7. We filed a ticket to Italian support.
From my side, the proposed solution also fixes the issue. Strangely, I am only encountering this problem on two systems. I assume a future 3CX update will provide a permanent fix?
 
From my side, the proposed solution also fixes the issue. Strangely, I am only encountering this problem on two systems. I assume a future 3CX update will provide a permanent fix?
In my case almost all our PBXs do the same error, since they all share the same backup server. I’m hoping for a fix and/or a Debian CLI commad to launch on all PBXs (at least the ones in our DC, more or less 300).
 
In my case almost all our PBXs do the same error, since they all share the same backup server. I’m hoping for a fix and/or a Debian CLI commad to launch on all PBXs (at least the ones in our DC, more or less 300).
It’s strange that only two of my systems with the same version and the same backup location are affected. In my case, Windows completely crashes and we have to force a restart when it happens. However, adding the key resolves the issue.
 

Forum statistics

Threads
111,954
Messages
589,921
Members
164,851
Latest member
DrunkeMeister