Script

FTP

The professional tool to automate FTP, SFTP, FTPS

and schedule FTP batch jobs

MENU MENU
Post here if you experience file transfer problems or unexpected errors.
I am trying to use SYNC command on a folder which has around 50,000 Images, size is around 800MB, problem is half way there during uploading ScriptFTP Fails and throws following error.

A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
425 Data channel timed out.
***** SYNC Error #425: Cannot upload local file 30336.jpg.
***** The server said: Data channel timed out.

i am using following script..

SYNC("C:\W\CH\Binary\main","/bm/main",UPLOAD,SUBDIRS,"*.jpg")


My FTP Server is Windows Server and Passive mode is enabled and working, what can i do to avoid this error?

Thanks
Hello,

Some FTP servers close the connection when they receive some heavy traffic and expect the client (ScriptFTP) to reconnect and continue the transfer.

You would need to relaunch SYNC if it returns an error (something different than OK)

[scriptftp="retry_sync.ftp"]:connect

OPENHOST("ftp.myhost.com","myuser","mypassword")

$result=SYNC("C:\W\CH\Binary\main","/bm/main",UPLOAD,SUBDIRS,"*.jpg")

# Check if $result is different from "OK"
IF($result!="OK")
PRINT("Cannot complete the synchronization! Trying again.")
GOTO :connect
END IF[/ScriptFTP]