Post a reply

Options
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)

Options

Topic review

martin

Re: Scripting - how to resume an interrupted upload

Please try the 4.2.3. Post a log file from that version if it does not help.
Guest

Scripting - how to resume an interrupted upload

Hi,

I'm currently testing using WinSCP.com (Version 4.1.9 Build 416) to see if it can resume an interrupted upload - but I cannot seem to get it to work.

When my script is presented with the options of Abort, Resume, Skip and Skip all - it always chooses Abort. Is there anyway I can get it to automatically choose Resume?

I've also tried adding the -resume swicth to the put command - but it just says unknown switch.

Thanks for any help.

Below is the output from my script plus the logfile.

winscp> option batch on

batch        on
winscp> option confirm off
confirm      off
winscp> open ftp://mylogin:********@***.***.***.***:21 -timeout=300
Connecting to ***.***.***.*** ...
Connected with ***.***.***.***. Waiting for welcome message...
Connected
Starting the session...
Reading remote directory...
Session started.
Active session: [1] mylogin@***.***.***.***
winscp> bin
transfer     binary
winscp> cd mylogin
/mylogin
winscp> put MyVeryBigFile.zip
MyVeryBigFile.zip               |      77712 KiB |    0.0 KiB/s | binary |  25%
Error transferring file 'MyVeryBigFile.zip'.
Copying files to remote side failed.
Opening BINARY mode data connection.  Ready to write file . ("/mylogin/MyVeryBigFile.
zip") S T O R
(A)bort, (R)etry, (S)kip, Ski(p) all: Abort
winscp>


. 2009-09-22 11:53:22.161 --------------------------------------------------------------------------

. 2009-09-22 11:53:22.161 WinSCP Version 4.1.9 (Build 416) (OS 5.2.3790 Service Pack 2)
. 2009-09-22 11:53:22.161 Login time: 22 September 2009 11:53:22
. 2009-09-22 11:53:22.161 --------------------------------------------------------------------------
. 2009-09-22 11:53:22.161 Session name: mylogin@***.***.***.***
. 2009-09-22 11:53:22.161 Host name: ***.***.***.*** (Port: 21)
. 2009-09-22 11:53:22.161 User name: mylogin (Password: Yes, Key file: No)
. 2009-09-22 11:53:22.161 Tunnel: No
. 2009-09-22 11:53:22.161 Transfer Protocol: FTP
. 2009-09-22 11:53:22.161 Ping type: C, Ping interval: 30 sec; Timeout: 300 sec
. 2009-09-22 11:53:22.161 Proxy: none
. 2009-09-22 11:53:22.161 FTP: Passive: No
. 2009-09-22 11:53:22.161 Local directory: default, Remote directory: home, Update: No, Cache: Yes
. 2009-09-22 11:53:22.161 Cache directory changes: Yes, Permanent: Yes
. 2009-09-22 11:53:22.161 DST mode: 1
. 2009-09-22 11:53:22.161 --------------------------------------------------------------------------
. 2009-09-22 11:53:22.201 Connecting to ***.***.***.*** ...
. 2009-09-22 11:53:22.201 Connected with ***.***.***.***. Waiting for welcome message...
< 2009-09-22 11:53:22.261 220-Welcome to CrushFTP4!
< 2009-09-22 11:53:22.261 220 CrushFTP Server Ready!
> 2009-09-22 11:53:22.261 USER mylogin
< 2009-09-22 11:53:22.271 331 Username OK.  Need password.
> 2009-09-22 11:53:22.271 PASS **********
< 2009-09-22 11:53:22.311 230 Password OK.  Connected.
> 2009-09-22 11:53:22.311 SYST
< 2009-09-22 11:53:22.311 215 UNIX Type: L8
> 2009-09-22 11:53:22.311 FEAT
< 2009-09-22 11:53:22.311 211-Extensions supported:
< 2009-09-22 11:53:22.431  AUTH TLS
< 2009-09-22 11:53:22.431  AUTH SSL
< 2009-09-22 11:53:22.431  SSCN
< 2009-09-22 11:53:22.431  PBSZ
< 2009-09-22 11:53:22.431  PROT
< 2009-09-22 11:53:22.431  CCC
< 2009-09-22 11:53:22.431  CLNT
< 2009-09-22 11:53:22.431  EPSV
< 2009-09-22 11:53:22.431  EPRT
< 2009-09-22 11:53:22.431  MDTM
< 2009-09-22 11:53:22.431  MDTM YYYYMMDDHHMMSS[+-TZ];filename
< 2009-09-22 11:53:22.431  SIZE
< 2009-09-22 11:53:22.431  REST STREAM
< 2009-09-22 11:53:22.431  MODE Z
< 2009-09-22 11:53:22.431  LIST -Q
< 2009-09-22 11:53:22.431  UTF8
< 2009-09-22 11:53:22.431 211 END
> 2009-09-22 11:53:22.431 CLNT FileZilla
< 2009-09-22 11:53:22.431 200 Noted.
> 2009-09-22 11:53:22.431 OPTS UTF8 ON
< 2009-09-22 11:53:22.431 200 UTF8 OPTS ON.
. 2009-09-22 11:53:22.431 Connected
. 2009-09-22 11:53:22.431 --------------------------------------------------------------------------
. 2009-09-22 11:53:22.431 Using FTP protocol.
. 2009-09-22 11:53:22.431 Doing startup conversation with host.
> 2009-09-22 11:53:22.441 PWD
< 2009-09-22 11:53:22.441 257 "/" PWD  command successful.
. 2009-09-22 11:53:22.451 Getting current directory name.
. 2009-09-22 11:53:22.451 Startup conversation with host finished.
. 2009-09-22 11:53:22.451 Cached directory change via "mylogin" to "/mylogin".
. 2009-09-22 11:53:22.451 Getting current directory name.
. 2009-09-22 11:53:22.451 Copying 1 files/directories to remote directory "/mylogin"
. 2009-09-22 11:53:22.451   PrTime: Yes; PrRO: No; Rght: rw-r--r--; PrR: No (No); FnCs: N; RIC: 01; Resume: Y (102400); CalcS: No; Mask:
. 2009-09-22 11:53:22.451   TM: B; ClAr: No; CPS: 0; ExclM(No):
. 2009-09-22 11:53:22.451   AscM: *.*html; *.htm; *.txt; *.php; *.php3; *.cgi; *.c; *.cpp; *.h; *.pas; *.bas; *.tex; *.pl; .htaccess; *.xtml; *.css; *.cfg; *.ini; *.sh; *.xml
. 2009-09-22 11:53:22.451 File: "MyVeryBigFile.zip"
. 2009-09-22 11:53:22.451 Copying "MyVeryBigFile.zip" to remote directory started.
. 2009-09-22 11:53:22.451 Binary transfer mode selected.
. 2009-09-22 11:53:22.451 Starting upload of MyVeryBigFile.zip
> 2009-09-22 11:53:22.451 CWD /mylogin/
< 2009-09-22 11:53:22.461 250 "/mylogin/" CWD command successful.
> 2009-09-22 11:53:22.461 PWD
< 2009-09-22 11:53:22.461 257 "/mylogin/" PWD  command successful.
> 2009-09-22 11:53:22.461 TYPE A
< 2009-09-22 11:53:22.461 200 Command ok : ASCII type selected.
> 2009-09-22 11:53:22.461 PORT 192,168,1,58,4,215
< 2009-09-22 11:53:22.461 200 PORT command successful. 192.168.1.58:1239.
> 2009-09-22 11:53:22.461 LIST
< 2009-09-22 11:53:22.471 150 Opening data connection for file list.
< 2009-09-22 11:53:22.632 226 Directory transfer complete. (generate:0ms)(send:0ms)
> 2009-09-22 11:53:22.632 TYPE I
< 2009-09-22 11:53:22.632 200 Command ok : Binary type selected.
> 2009-09-22 11:53:22.632 PORT 192,168,1,58,4,216
< 2009-09-22 11:53:22.632 200 PORT command successful. 192.168.1.58:1240.
> 2009-09-22 11:53:22.632 STOR MyVeryBigFile.zip
< 2009-09-22 11:53:22.662 150 Opening BINARY mode data connection.  Ready to write file . ("/mylogin/MyVeryBigFile.zip") S T O R
. 2009-09-22 11:53:46.376 Copying files to remote side failed.
* 2009-09-22 11:53:46.406 (ExtException) Copying files to remote side failed.
* 2009-09-22 11:53:46.406 Opening BINARY mode data connection.  Ready to write file . ("/mylogin/MyVeryBigFile.zip") S T O R
. 2009-09-22 11:53:46.406 Asking user:
. 2009-09-22 11:53:46.406 Error transferring file 'MyVeryBigFile.zip'. ("Copying files to remote side failed.","Opening BINARY mode data connection.  Ready to write file . (""/mylogin/MyVeryBigFile.zip"") S T O R")
* 2009-09-22 11:53:46.406 (EScpSkipFile) Error transferring file 'MyVeryBigFile.zip'.
* 2009-09-22 11:53:46.406 Copying files to remote side failed.
* 2009-09-22 11:53:46.406 Opening BINARY mode data connection.  Ready to write file . ("/mylogin/MyVeryBigFile.zip") S T O R
. 2009-09-22 11:53:46.406 Disconnected from server