Topic "Error Transfer was successfully finished, but temporary transfer file name.filepart'"

Author Message
Naren123

Guest


I'm new to Winscp scripting and trying to upload multiple files to SFTP server using below script.


Sample.txt
------------
option echo off
option batch abort
option confirm off
# Connect to SFTP server using a password
open sftp://xxxx:xxxxx@xxxxx/ -hostkey="ssh-rsa 1024 2d:3d:c0:26:54:08:cf:bc:ad:20:80:46:5a:fa:66:db
cd /INBD/TEST
put B:\INVOICES\Testing_Files\*.*
# Exit WinSCP
exit
-------------------
.bat file
@echo off
winscp.com /ini=nul /log=B:\INVOICES\Testing_Files\winscp.log /script=H:\mk\sample1.txt
pause
----------------
below is my error message and log.same script working fine with FTP server.

Transfer was successfully finished, but temporary transfer file 'INVOICE.filepart' could not be renamed to target file name 'INVOICE'. If the problem persists, you may try to t


. 2017-02-27 10:07:20.281 Using SFTP protocol.
. 2017-02-27 10:07:20.281 Doing startup conversation with host.
> 2017-02-27 10:07:20.281 Type: SSH_FXP_INIT, Size: 5, Number: -1
< 2017-02-27 10:07:20.281 Type: SSH_FXP_VERSION, Size: 5, Number: -1
. 2017-02-27 10:07:20.281 SFTP version 3 negotiated.
. 2017-02-27 10:07:20.281 We believe the server has signed timestamps bug
. 2017-02-27 10:07:20.296 We will use UTF-8 strings until server sends an invalid UTF-8 string as with SFTP version 3 and older UTF-8 strings are not mandatory
. 2017-02-27 10:07:20.296 Getting current directory name.
. 2017-02-27 10:07:20.296 Getting real path for '.'
> 2017-02-27 10:07:20.296 Type: SSH_FXP_REALPATH, Size: 10, Number: 16
< 2017-02-27 10:07:20.296 Type: SSH_FXP_NAME, Size: 23, Number: 16
. 2017-02-27 10:07:20.296 Real path is '/'
. 2017-02-27 10:07:20.296 Startup conversation with host finished.
< 2017-02-27 10:07:20.296 Script: Active session: [1] ZZDD1900@editps.dhmh.state.md.us
> 2017-02-27 10:07:20.296 Script: cd /INBD/TEST
. 2017-02-27 10:07:20.296 Changing directory to "/INBD/TEST".
. 2017-02-27 10:07:20.296 Getting real path for '/INBD/TEST'
> 2017-02-27 10:07:20.296 Type: SSH_FXP_REALPATH, Size: 19, Number: 272
< 2017-02-27 10:07:20.312 Type: SSH_FXP_NAME, Size: 41, Number: 272
. 2017-02-27 10:07:20.312 Real path is '/INBD/TEST'
. 2017-02-27 10:07:20.312 Trying to open directory "/INBD/TEST".
> 2017-02-27 10:07:20.312 Type: SSH_FXP_LSTAT, Size: 19, Number: 519
< 2017-02-27 10:07:20.312 Type: SSH_FXP_ATTRS, Size: 21, Number: 519
. 2017-02-27 10:07:20.312 Getting current directory name.
< 2017-02-27 10:07:20.312 Script: /INBD/TEST
> 2017-02-27 10:07:20.312 Script: put B:\INVOICES\MMIS_Testing_Files\*.*
. 2017-02-27 10:07:20.328 Copying 6 files/directories to remote directory "/INBD/TEST"
. 2017-02-27 10:07:20.328 PrTime: Yes; PrRO: No; Rght: rw-r--r--; PrR: No (No); FnCs: N; RIC: 0100; Resume: S (102400); CalcS: No; Mask:
. 2017-02-27 10:07:20.328 TM: B; ClAr: No; RemEOF: No; RemBOM: No; CPS: 0; NewerOnly: No; InclM: ; ResumeL: 0
. 2017-02-27 10:07:20.328 AscM: *.*html; *.htm; *.txt; *.php; *.php3; *.cgi; *.c; *.cpp; *.h; *.pas; *.bas; *.tex; *.pl; *.js; .htaccess; *.xtml; *.css; *.cfg; *.ini; *.sh; *.xml
. 2017-02-27 10:07:20.343 File: 'B:\INVOICES\MMIS_Testing_Files\MMIS_INVOICE_837_05070_3' [2016-08-05T18:09:41.487Z] [2220113]
. 2017-02-27 10:07:20.343 Copying "B:\INVOICES\MMIS_Testing_Files\MMIS_INVOICE_837_05070_3" to remote directory started.
. 2017-02-27 10:07:20.343 Binary transfer mode selected.
. 2017-02-27 10:07:20.343 Checking existence of file.
> 2017-02-27 10:07:20.359 Type: SSH_FXP_LSTAT, Size: 44, Number: 775
< 2017-02-27 10:07:20.359 Type: SSH_FXP_STATUS, Size: 33, Number: 775
< 2017-02-27 10:07:20.359 Status code: 2
. 2017-02-27 10:07:20.359 Checking existence of partially transfered file.
> 2017-02-27 10:07:20.359 Type: SSH_FXP_LSTAT, Size: 53, Number: 1031
< 2017-02-27 10:07:20.359 Type: SSH_FXP_STATUS, Size: 33, Number: 1031
< 2017-02-27 10:07:20.359 Status code: 2
. 2017-02-27 10:07:20.359 Opening remote file.
> 2017-02-27 10:07:20.359 Type: SSH_FXP_OPEN, Size: 69, Number: 1283
< 2017-02-27 10:07:20.374 Type: SSH_FXP_HANDLE, Size: 10, Number: 1283
> 2017-02-27 10:07:20.374 Type: SSH_FXP_WRITE, Size: 32790, Number: 1798
. 2017-02-27 10:07:20.640 116 skipped SSH_FXP_WRITE, SSH_FXP_READ, SSH_FXP_DATA and SSH_FXP_STATUS packets.
> 2017-02-27 10:07:20.640 Type: SSH_FXP_CLOSE, Size: 10, Number: 17924
< 2017-02-27 10:07:20.640 Type: SSH_FXP_STATUS, Size: 21, Number: 15622
< 2017-02-27 10:07:20.640 Status code: 0
< 2017-02-27 10:07:20.640 Type: SSH_FXP_STATUS, Size: 21, Number: 15878
< 2017-02-27 10:07:20.640 Type: SSH_FXP_STATUS, Size: 21, Number: 16134
< 2017-02-27 10:07:20.640 Type: SSH_FXP_STATUS, Size: 21, Number: 16390
< 2017-02-27 10:07:20.655 Type: SSH_FXP_STATUS, Size: 21, Number: 16646
< 2017-02-27 10:07:20.655 Type: SSH_FXP_STATUS, Size: 21, Number: 16902
< 2017-02-27 10:07:20.655 Type: SSH_FXP_STATUS, Size: 21, Number: 17158
< 2017-02-27 10:07:20.796 Type: SSH_FXP_STATUS, Size: 21, Number: 17414
< 2017-02-27 10:07:20.796 Type: SSH_FXP_STATUS, Size: 21, Number: 17670
< 2017-02-27 10:07:20.796 Type: SSH_FXP_STATUS, Size: 21, Number: 17924
< 2017-02-27 10:07:20.796 Status code: 0
> 2017-02-27 10:07:20.796 Type: SSH_FXP_RENAME, Size: 92, Number: 18194
< 2017-02-27 10:07:20.796 Type: SSH_FXP_STATUS, Size: 33, Number: 18194
< 2017-02-27 10:07:20.796 Status code: 2, Message: 18194, Server: File not found, Language: en
* 2017-02-27 10:07:20.796 (ETerminal) No such file or directory.
* 2017-02-27 10:07:20.796 Error code: 2
* 2017-02-27 10:07:20.796 Error message from server (en): File not found
. 2017-02-27 10:07:20.796 Asking user:
. 2017-02-27 10:07:20.796 Transfer was successfully finished, but temporary transfer file 'MMIS_INVOICE_837_05070_3.filepart' could not be renamed to target file name 'MMIS_INVOICE_837_05070_3'. If the problem persists, you may try to turn off transfer resume support. ("No such file or directory.
. 2017-02-27 10:07:20.796 Error code: 2
. 2017-02-27 10:07:20.796 Error message from server (en): File not found")
< 2017-02-27 10:07:20.796 Script: Transfer was successfully finished, but temporary transfer file 'MMIS_INVOICE_837_05070_3.filepart' could not be renamed to target file name 'MMIS_INVOICE_837_05070_3'. If the problem persists, you may try to turn off transfer resume support.
< 2017-02-27 10:07:20.796 Script: No such file or directory.
< 2017-02-27 10:07:20.796 Error code: 2
< 2017-02-27 10:07:20.811 Error message from server (en): File not found
* 2017-02-27 10:07:20.811 (EScpSkipFile) Transfer was successfully finished, but temporary transfer file 'MMIS_INVOICE_837_05070_3.filepart' could not be renamed to target file name 'MMIS_INVOICE_837_05070_3'. If the problem persists, you may try to turn off transfer resume support.
* 2017-02-27 10:07:20.811 No such file or directory.
* 2017-02-27 10:07:20.811 Error code: 2
* 2017-02-27 10:07:20.811 Error message from server (en): File not found
. 2017-02-27 10:07:20.811 Script: Failed
. 2017-02-27 10:07:20.811 Script: Exit code: 1
. 2017-02-27 10:07:20.811 Closing connection.
. 2017-02-27 10:07:20.811 Sending special code: 12
. 2017-02-27 10:07:20.811 Sent EOF message
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25966
Location: Prague, Czechia
Did you read the documentation?
https://winscp.net/eng/docs/message_transfer_finished_could_not_rename
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