ftp automation

ScriptFTP

The professional tool to automate FTP, SFTP, FTPS and schedule FTP batch jobs

The forum is now read only. Please, go to the the main ScriptFTP website if you need help.
Post here if you experience file transfer problems or unexpected errors.
Hi

I have a strange problem that you maybe can help me with. I do a sync of files every morning
but after the sync process is done, scriptftp.exe is not closing and after for example a week
I have seven scriptftp.exe processes running.

I have checked the log files and can see this
Skipping (remote file is up to date) 188034-0069-00-10236.pdf
Skipping (remote file is up to date) 188034-0071-00-10236.pdf
Uploading (remote file not found) 188034-0083-00-10236-01.pdf
***** SYNC Error #17421: Cannot upload local file 188034-0083-00-10236-01.pdf.
***** The server said: Service not available, closing control connection.


CLOSEHOST
***** CLOSEHOST Error #18001: Not connected.

[scriptftp="sync.ftp"]$date=GETDATE(FORMAT2)
#Concatenate "BACKUP" with the current date and ".txt" to build the log file name
$logfile="C:\SCC\script\ ".$date. ".txt"

#start logging into logfile
LOGTO($logfile)

# Connect to FTP server
OPENHOST("127.0.0.1","xxxxxxxx","xxxxxxxxx")

# Send all the files and subdirectories in C:\MyDir to the server
SYNC("\\computer3212\data\30\004xxxx","/",UPLOAD,SUBDIRS)

# Transfer finished, close the connection
CLOSEHOST[/ScriptFTP]
Try adding the EXIT command at the bottom of your script file. This will force ScriptFTP to quit when the script has finished. This way you will not find any scripts still running.
***** SYNC Error #17421: Cannot upload local file 188034-0083-00-10236-01.pdf.
***** The server said: Service not available, closing control connection.
The syncronization is not finished because the FTP server has unexpectedly closed the connection. I've seen the you us an IP address in the OPENHOST field. Do you have administrator access to the FTP server? If so it would be very useful if you take a look at the server log. Probably there you will find the reason why it closed the connection.
Thanks, I will try with a EXIT command at the end

Yes, I have admin rights. I have checked that. I do a sync every day with at least 1000 files and most of them is syncing correct.
Thanks for the update jlars