Post a reply

Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)


Topic review


Not if you set the Scheduled Task to run to "Run whether user is logged on or not".
It will run the batch file with the credentials you specify in the background.
If the task is set to run at startup then it will run as soon as your machine boots up.
And it's always an idea to select the "Run with highest privileges" box.


But then user needs to be logged in all thentime?

yes, you will need to keep it running.

A schedule task set to start when the system boots and checks every 5 minutes to make sure it's running should help keep it running.
It's the same set up I am using to do a similar task.



I made a .bat file with :

@echo on

"C:\Program Files (x86)\WinSCP\" /ini=nul /command "option batch continue" "option confirm off" "open ftp://admin:password@" "keepuptodate -resumesupport=on D:\Mainfolder\folder /Mainfolder/FOLDER"

if %WINSCP_RESULT% equ 0 (
echo Success
) else (
echo Error

, BUT does the .bat windows need to be open all the time then ?

My goal is to make a realtime sync between a local and a remote server.
where data from the local server is mirrored to the remote server. (this remote server runs Filezilla Server)

Thanks, working perfectly.
Just another question about sync option. Is it possible to have it uploading more than one file at a time?

Re: Auto keepuptodate

WinSCP defaults to SFTP. So if you want to connect using FTP, you have to tell it explicitly, like open

Auto keepuptodate

I've been looking for the script for this but so far it doesn't seem to wan to work for me.
I want to have a sync between two servers that will add new and delete old from the destination.

I have got as far as the getting the following but it's not even registering on the remote server that it's trying to connect.

Batch file runs:
"C:\Program Files (x86)\WinSCP\winscp.exe" /command /script-C:\Datastore\SC2-Script.txt /log=C:\DataStore\WinSCP.log

Script is set to (the files to sync are in the root directory when you log into the FTP):
option batch on

option confirm off
option batch continue
keepuptodate -delete -resumesupport=on Q:\DE /

Where am I going wrong?
All help is appreciated.