Topic "Trouble with file resume while synching folders..."

Author Message
suicidejack

Guest


I came across your program about a month ago and I am having some trouble. What I am trying to do is a simple ftp backup that occurs during the night. I have accomplished this by scheduling a task that starts at 8:00pm and is only allowed to run for 12 hours.

The task is:
"winscp.exe" backupsite /synchronize X:\OSBackup /User /defaults

This works great... Very Happy

Except for when a file is to large to be transmitted in the allowed 12 hours. Sad

What I am running into is when the connection is broken in the morning and only part of the file is transmitted, when it reconnects the next night it see's that the 2 files are different sizes and delete's the one on the remote server and starts over again. Is there any way to get it to resume the previous file?

To answer some questions in advanced:
I have file resume enable.
The ftp server supports file resume.
I am comparing files by size. (I have tried modification time but
it just skips over the incomplete file)

Any help or nudges in the right direction would be greetly appreciated.
Advertisements
suicidjack

Guest


Upon reading more into the synchronize command I don't think that it will work for what I am trying to do. Sad

But I did find that I would probably have more luck with the upload command. I have changed my task to:

"winscp.exe" backupsite /upload X:\OSBackup\ /User /defaults

I am using ftp as the protocol and the manual resume works when I have the overwrite confirmations box checked but I have to click on resume when the task runs. I was wondering is there a way to get it to automaticly do file resume instead of overwite?

Again thanks in advance...
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
First, for automation use scripting.

With scripting you can limit bandwidth, so you can run your backup whole day.
_________________
Martin Prikryl
suicidejack

Guest


Running the transfer all day really isn't an option because the internet connection is so slow. But I am having luck with the scripts.

what I have so far:

script.txt

open mybackupsite
put c:\winscp\backup\*.* /

and a visual basic script to launch it,

script.vbs

Set Command = WScript.CreateObject("WScript.Shell")
cmd = "C:\winscp\winscp.exe /console /script=script.txt"
Command.Run (cmd)

What I am having trouble with is if the file has already been transferred completely then the conole doesn't give me an option to resume only to overwrite. If this is the case I need to send the "n" key to tell it not to over right it. but if it's not complete then I need to send the "r" key to tell it to resume.

I was thinking something like:

if resume is an option
sendkey "r"
else
sendkey "n"

but for this to work I will need a way to tell if resume is one of the options listed in the console.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
Btw, what protocol are you using?
_________________
Martin Prikryl
suicidejack

Guest


I am using plain old ftp. I thought about using sftp because it appears that it handles file resume better but I'm concerned about the speed of the transfer and It looks a little complicated to setup both client side and server side.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25015
Location: Prague, Czechia
Hm, with FTP it definitely won't work (not sure about SFTP now). Anyway this is being tracked already.
suicidejack

Guest


This is a feature that would realy help alot of people out so it's good to know that it is being looked at. I am going to try my luck with sftp (which means no more bulletproof server Crying or Very sad )

Other than that an excellent program.

Keep up the good work. Smile
suicidejack

Guest


Made the switch to sftp and synchronize and file resume works like a carm.. Very Happy

I did away with my bulletproof ftp server, Sad discovered that gene 6 does ftps and not sftp Crying or Very sad so I am using coreftp server right now but was wanting to step up to something a little better. I was wondering if anyone could suggest a good sftp server. I know very little about linux so I am trying to stay away from openssh as well.
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License