temporary file (.filepart?) and synchronize resume on FTPS

Advertisement

Federico
Joined:
Posts:
2
Location:
Monaco

temporary file (.filepart?) and synchronize resume on FTPS

Good day,
I'm a newbie and I'm asking for support (sorry).
Objective: update a remote FTPS (not SFTP) with the latest content of a local folder, resuming on partial transfer, by scripting.
Problem : I'm unable to see the temporary filename and unable to resume an upload using the command synchronize

Yes, I've read at my best and understood "Transfer to temporary filename is supported with SFTP protocol only and only for binary transfers."
So my first question : why is not possible to create a temporary file to/from an FTP/FTPS with a dedicated temporary extension and rename when complete ?

I see that a "resume" feature works also on FTP/FTPS, but I'm only able able to resume using
"put -resumesupport=on -resume ... " that works (again without temporary filename).
"synchronize -resumesupport=on remote " does not resume (or is missing the same -resume feature necessary for the put).

My "workaround" solution is:

option echo on
option batch on
option confirm off
open FTPSserver_session
put -resumesupport=on -resume -neweronly c:\localfolder\* /
synchronize -delete -preservetime remote c:\localfolder /
put -resumesupport=on -resume -latest c:\localfolder\* /

first put is able to upload and resume incomplete so do most of the hard work at the beginning
first synchronize delete remote files missing from local folder
second put update lastest version of the local files (as it seems that combining on first put -neweronly and -latest miss the timestamp check)

WinSCP 5.9.5 on Win10 64 protocol FTPS by scripting
FTPS server is IIS 7.5 on W7 with "keep partial upload=True" "Allow reading files while uploading=True" "Allow replace on rename=True".

Thanks in advance to everybody that wish help me understand better and/or suggest a "cleaner" way to achieve my objective.

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
29,476
Location:
Prague, Czechia

Re: temporary file (.filepart?) and synchronize resume on FTPS

Indeed, the automatic resume is not supported for FTP(S).

Blindly using -resume this way is not a good idea. You may end up combining contents of different versions of files. Do not do that.

There's no magic solution to your problem, unfortunately.

Reply with quote

Federico
Joined:
Posts:
2
Location:
Monaco

sad news

anyway thanks Martin
I hope this post may help other newbie (like me) to clear their doubts.
Thanks again for the quick answer and for your commitment.

Reply with quote

Advertisement

You can post new topics in this forum