Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

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

lravens19

THANK YOU

thank you very much martin. i Made that change to the script last week and so far i have not had the process get hung up. THAnk you for ellaborating on the support documentation.
martin

Re: (ExtException) Copying files to remote side failed

lravens19 wrote:

Hey martin doesn't option batch abort end the script if any errors occur?
"With abort script is aborted when any error occurs."

Actually not in this case.
But anyway, please "option batch on" would do too.
I have elaborated more on the behavior of the option batch command in documentation:
https://winscp.net/eng/docs/scriptcommand_option
lravens19

(ExtException) Copying files to remote side failed

Hey martin doesn't option batch abort end the script if any errors occur?
"With abort script is aborted when any error occurs."

I don't want the script to abort I want it to retry. On days when this script fails I turn to the GUI to manually transfer the files. The gui transfer will fail but it gives me an option to retry I click retry and it transfers the file and continues to transfer the remaining files.
martin

Re: (ExtException) Copying files to remote side failed

The script should retry automatically. But you need to specify the "option batch abort" to avoid the interactive prompts.
lravens19

(ExtException) Copying files to remote side failed

Hey Martin, no the files change every single day. They are radiology images that are being transferred out. So who ever got an MRI read and resulted today at the hospital I have to transfer it tomorrow morning. Some days there are only 40-50 files I transfer and other days there are 200-500 file I transfer. The process seems to fail when there are over 200 files. Do my logs show that it's running in passive mode? Is there anyway to force the file transfer to retry to send the file?
martin

Re: (ExtException) Copying files to remote side failed

So does it always break on the same file? Even if you are uploading on the single one?
lravens19

(ExtException) Copying files to remote side failed

Winscp: version 4.3.3 (Build 1340)
Windows Server 2000 SP4 (DON'T LAUGH!!)
Protocol: FTP
I use Scripting/Automation for file transfer

Here is my log file:
. 2011-08-25 04:00:56.494 --------------------------------------------------------------------------
. 2011-08-25 04:00:56.494 WinSCP Version 4.3.3 (Build 1340) (OS 5.0.2195 Service Pack 4)
. 2011-08-25 04:00:56.509 Configuration: c:\winnt\WinSCP.ini
. 2011-08-25 04:00:56.509 Login time: Thursday, August 25, 2011 4:00:56 AM
. 2011-08-25 04:00:56.509 --------------------------------------------------------------------------
. 2011-08-25 04:00:56.509 Session name: PPMC (Stored session)
. 2011-08-25 04:00:56.509 Host name: 192.168.155.10 (Port: 21)
. 2011-08-25 04:00:56.509 User name: ***** (Password: Yes, Key file: No)
. 2011-08-25 04:00:56.525 Tunnel: No
. 2011-08-25 04:00:56.525 Transfer Protocol: FTP
. 2011-08-25 04:00:56.525 Ping type: C, Ping interval: 30 sec; Timeout: 15 sec
. 2011-08-25 04:00:56.525 Proxy: none
. 2011-08-25 04:00:56.525 FTP: FTPS: None; Passive: Yes [Force IP: No]
. 2011-08-25 04:00:56.525 Local directory: default, Remote directory: home, Update: No, Cache: Yes
. 2011-08-25 04:00:56.525 Cache directory changes: Yes, Permanent: Yes
. 2011-08-25 04:00:56.525 DST mode: 1
. 2011-08-25 04:00:56.525 --------------------------------------------------------------------------
. 2011-08-25 04:00:56.634 Connecting to 192.168.155.10 ...
. 2011-08-25 04:00:56.837 Connected with 192.168.155.10. Waiting for welcome message...
< 2011-08-25 04:00:56.916 220 Welcome to PPMC FTP service.
> 2011-08-25 04:00:56.916 USER *******
< 2011-08-25 04:00:57.025 331 Please specify the password.
> 2011-08-25 04:00:57.025 PASS *******
< 2011-08-25 04:00:57.291 230 Login successful.
> 2011-08-25 04:00:57.291 SYST
< 2011-08-25 04:00:57.416 215 UNIX Type: L8
> 2011-08-25 04:00:57.416 FEAT
< 2011-08-25 04:00:57.509 211-Features:
< 2011-08-25 04:00:57.509 EPRT
< 2011-08-25 04:00:57.509 EPSV
< 2011-08-25 04:00:57.509 MDTM
< 2011-08-25 04:00:57.509 PASV
< 2011-08-25 04:00:57.650 REST STREAM
< 2011-08-25 04:00:57.650 SIZE
< 2011-08-25 04:00:57.650 TVFS
< 2011-08-25 04:00:57.650 UTF8
< 2011-08-25 04:00:57.650 211 End
> 2011-08-25 04:00:57.650 OPTS UTF8 ON
< 2011-08-25 04:00:57.744 200 Always in UTF8 mode.
. 2011-08-25 04:00:57.744 Connected
. 2011-08-25 04:00:57.744 --------------------------------------------------------------------------
. 2011-08-25 04:00:57.744 Using FTP protocol.
. 2011-08-25 04:00:57.759 Doing startup conversation with host.
> 2011-08-25 04:00:57.775 PWD
< 2011-08-25 04:00:57.869 257 "/"
. 2011-08-25 04:00:57.884 Getting current directory name.
. 2011-08-25 04:00:57.884 Startup conversation with host finished.
< 2011-08-25 04:00:57.884 Script: Active session: [1] PPMC
> 2011-08-25 04:00:57.900 Script: cd /reports
. 2011-08-25 04:00:57.900 Cached directory change via "/reports" to "/reports".
. 2011-08-25 04:00:57.900 Getting current directory name.
< 2011-08-25 04:00:57.900 Script: /reports
> 2011-08-25 04:00:57.916 Script: lcd "D:\FileTransfers\PPMCReports"
< 2011-08-25 04:00:57.916 Script: D:\FileTransfers\PPMCReports
> 2011-08-25 04:00:57.916 Script: put "*.txt"
. 2011-08-25 04:00:57.916 Copying 225 files/directories to remote directory "/reports"
. 2011-08-25 04:00:57.916 PrTime: No; PrRO: Yes; Rght: rw-rw-rw-; PrR: No (Yes); FnCs: N; RIC: 01; Resume: N (102400); CalcS: No; Mask:
. 2011-08-25 04:00:57.916 TM: M; ClAr: No; CPS: 0; ExclM(No):
. 2011-08-25 04:00:57.916 AscM: *.*html; *.htm; *.txt; *.php; *.php3; *.cgi; *.c; *.cpp; *.h; *.pas; *.bas; *.tex; *.pl; .htaccess; *.xtml; *.css; *.cfg; *.ini; *.sh; *.xml
. 2011-08-25 04:00:57.916 File: " pCR1219044_0.txt"
. 2011-08-25 04:00:57.931 Copying " pCR1219044_0.txt" to remote directory started.
. 2011-08-25 04:00:57.931 Ascii transfer mode selected.
. 2011-08-25 04:00:57.931 Starting upload of file.txt
> 2011-08-25 04:00:57.931 CWD /reports/
< 2011-08-25 04:00:58.041 250 Directory successfully changed.
> 2011-08-25 04:00:58.041 PWD
< 2011-08-25 04:00:58.150 257 "/reports"
> 2011-08-25 04:00:58.150 TYPE A
< 2011-08-25 04:00:58.244 200 Switching to ASCII mode.
> 2011-08-25 04:00:58.244 PASV
< 2011-08-25 04:00:58.353 227 Entering Passive Mode (192,168,155,10,27,74).
> 2011-08-25 04:00:58.384 LIST
< 2011-08-25 04:00:58.619 150 Here comes the directory listing.
< 2011-08-25 04:00:58.712 226 Directory send OK.
> 2011-08-25 04:00:58.728 TYPE A
< 2011-08-25 04:00:58.837 200 Switching to ASCII mode.
> 2011-08-25 04:00:58.837 PASV
< 2011-08-25 04:00:58.947 227 Entering Passive Mode (192,168,155,10,144,185).
> 2011-08-25 04:00:58.962 pCR1219044_0.txt
< 2011-08-25 04:00:59.166 150 Ok to send data.
< 2011-08-25 04:00:59.400 226 File receive OK.
. 2011-08-25 04:00:59.400 Upload successful
. 2011-08-25 04:00:59.416 File: " pCR1219045_0.txt"
. 2011-08-25 04:00:59.447 Copying "pCR1219045_0.txt" to remote directory started.
. 2011-08-25 04:00:59.447 Ascii transfer mode selected.
. 2011-08-25 04:00:59.447 Starting upload of pCR1219045_0.txt
> 2011-08-25 04:00:59.447 TYPE A
< 2011-08-25 04:00:59.556 200 Switching to ASCII mode.
> 2011-08-25 04:00:59.556 PASV
< 2011-08-25 04:00:59.666 227 Entering Passive Mode (192,168,155,10,95,73).
> 2011-08-25 04:00:59.666 pCR1219045_0.txt
< 2011-08-25 04:00:59.884 150 Ok to send data.
< 2011-08-25 04:01:00.197 226 File receive OK.
. 2011-08-25 04:01:00.197 Upload successful

:D THIS GOES ON FOR ANOTHER 230 FILES FINE. Then this is the specific file below that fails and halts the entire process. These files have patient names in the title so I cannot edit the entire log to wipe out all of their names to comply with HIPPA.

. 2011-08-25 04:03:09.370 File: "pCR1219224_0.txt"
. 2011-08-25 04:03:09.386 Copying "pCR1219224_0.txt" to remote directory started.
. 2011-08-25 04:03:09.386 Ascii transfer mode selected.
. 2011-08-25 04:03:09.386 Starting upload of pCR1219224_0.txt
> 2011-08-25 04:03:09.386 TYPE A
< 2011-08-25 04:03:09.480 200 Switching to ASCII mode.
> 2011-08-25 04:03:09.480 PASV
< 2011-08-25 04:03:09.589 227 Entering Passive Mode (192,168,155,10,26,12).
> 2011-08-25 04:03:09.589 pCR1219224_0.txt
. 2011-08-25 04:03:09.589 Copying files to remote side failed.
* 2011-08-25 04:03:09.589 (ExtException) Copying files to remote side failed.
* 2011-08-25 04:03:09.589 Entering Passive Mode (192,168,155,10,26,12).
. 2011-08-25 04:03:09.589 Asking user:
. 2011-08-25 04:03:09.589 Error transferring file pCR1219224_0.txt'. ("Copying files to remote side failed.","Entering Passive Mode (192,168,155,10,26,12).")


HERE IS MY SCRIPT
del /q "D:\FileTransfers\PPMCReports\*.pdf"

rem connect to PPMC and put todays file
echo open PPMC > D:\FileTransfers\PPMCreport.txt
echo cd /reports >> D:\FileTransfers\PPMCreport.txt
echo lcd "D:\FileTransfers\PPMCReports" >> D:\FileTransfers\PPMCreport.txt
echo put "*.txt" >> D:\FileTransfers\PPMCreport.txt
rem echo synchronize local D:\FileTransfers\PPMCReports\synch /reports -permissions=777 >> D:\FileTransfers\PPMCreport.txt
rem echo ls >> D:\FileTransfers\PPMCreport.txt
echo bye >> D:\FileTransfers\PPMCreport.txt

rem run winscp
c:\winnt\winscp.exe /log=D:\FileTransfers\repoPPMC%year%%month%%day%.txt /console /script=D:\FileTransfers\PPMCreport.txt



I looked through the forums but the only related issue I could see was people trying to switch directories and then pull a file from a remote ftp server. I'm trying to push a local file out to a remote ftp server.This problem seems to happen when I have over 200 files to transfer. This is the only consistency I can find for my problem. I've tried to run the process manually to see if I get the error in the GUI and I do. However, there is an option to retry. I click retry and then the file transfer resumes. I have my endurance setup to automatically reconnect session if it breaks during transfer and while idle. This problem was occuring on the previous winscp version so I upgraded to 4.3.3 and the problem still occurs. I would just like to look at everything from my side of things. The FTP server I post to is at a customer site and I do not know the specs of it. The files transfer over a VPN tunnel. My organization does not have logging on our VPN tunnels. They can only determine the current status of VPN tunnels they cannot look in the past. I know FRUSTRATING!