Data connection unexpectedly closed using WinSCP.com

Advertisement

JEvans_ARAS
Joined:
Posts:
3

Data connection unexpectedly closed using WinSCP.com

Hi:

We are experiencing an intermittent failure using WinSCP.com (version 5.7.5) while trying uploads to a remote server. The behavior is not predictable but happens consistently when it happens. Here is a current example:

C:\Users\jevans\Downloads>WinSCP.com /command "open ftp:/xxxxxx@xxxxxx/ -rawsettings /passive=on /explicit FtpForcePasvIp2=0" "put -preservetime xxxxxxx.zip xxxxxxxxxxx\/" "exit"
Connecting to xxxxxxxx ...
Connected
Starting the session...
Session started.
Active session: [1] xxxxxxxxxxxx. | 77664 KB | 3107.6 KB/s | binary | 46%
Error transferring file 'xxxxxxxx.zip'.
Copying files to remote side failed.
Data connection unexpectedly closed, receive file xxxxxxxx.zip aborted.
(A)bort, (R)etry, (S)kip, Ski(p) all: Abort

We have tried with and without the /passive=on and /explicit switches as it would appear they aren't supported on the WinSCP.Com file version.

Thoughts?

Thanks in advance for your help!

Reply with quote

Advertisement

JEvans_ARAS
Joined:
Posts:
3

Update - problem resolved but still have a question

Hi:

We were able to address the issue by adding the "-explicit" switch to the end of the commands in the open section. We then added this to our NAnt build scripts - along with the creation of the necessary certificates in the WinSCP.ini file - and thankfully our builds are no longer failing (which is very awesome).

The question that remains is why does this only happen very rarely and only with certain files? Size/naming convention/location do not seem to be relevant variables and 95% of the time, everything is fine. Only on rare occasions do we need explicit mode enabled and the challenge for a certificate using TLS. Any thoughts around that?

Thanks!

Reply with quote

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

Re: Update - problem resolved but still have a question

But you already had the /explicit in your script.

Is there anything relevant regarding the disconnect in the FTP server log?

Also note that you have two mistakes in the script:
- FtpForcePasvIp2=0 - this is missing -rawsetttings before.
- xxxxxxxxxxx\/ - The backlash should not be there, most probably.

Reply with quote

JEvans_ARAS
Joined:
Posts:
3

Re: Update - problem resolved but still have a question

martin wrote:

But you already had the /explicit in your script.

Is there anything relevant regarding the disconnect in the FTP server log?

Also note that you have two mistakes in the script:
- FtpForcePasvIp2=0 - this is missing -rawsetttings before.
- xxxxxxxxxxx\/ - The backlash should not be there, most probably.

Appreciate the correction, Martin. Unfortunately it is proving problematic to get at the logs but I will keep trying.

My thanks for your help. :)

Reply with quote

Advertisement

You can post new topics in this forum