Topic "Timeout waiting for external console to complete the command"

Author Message
grvdutt

Guest


Hi,

I'm getting following error while running from the batch script.

Timeout waiting for external console to complete the command. External console output is redirected to a pipe. Make sure the pipe is being read from.

Following is the batch script:

@ECHO OFF
mode 80,5000
title IndusInd file transfer utility
echo File tranfer utility IndusInd bank -version 1.0 -Gaurav Dutt
color 79
:loop
echo Copying...
echo echo off
echo option batch abort > ftp_uat.tmp
echo option confirm off >> ftp_uat.tmp
echo open orauat -rawsettings SendBuf=0 >> ftp_uat.tmp
echo call sh /apps_Prod/compare.sh >> ftp_uat.tmp
rem echo cd /orahome/db/PROD/db/tech_st/11.1.0/appsutil/outbound/CLONE_oraerptest >> ftp_uat.tmp
rem echo lcd C:\ERPIConfig\CSS\SOAPSender_mid >> ftp_uat.tmp
echo echo on >> ftp_uat.tmp
echo get -transfer=binary -preservetime -resumesupport=on -delete /home/orauat/utility/test/*.* C:\ERPIConfig\CSS\SOAPSender_mid\ >> ftp_uat.tmp
echo echo removing files.... >> ftp_uat.tmp
echo rm /orahome/db/PROD/db/tech_st/11.1.0/appsutil/outbound/CLONE_oraerptest/* >> ftp_uat.tmp
echo exit >> ftp_uat.tmp
"C:\Program Files\WinSCP\WinSCP.com" /script=ftp_uat.tmp
ping -n 10 127.0.0.1 > nul
DEL ftp_uat.tmp
goto loop
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25019
Location: Prague, Czechia
grvdutt wrote:
External console output is redirected to a pipe.

Is it?

Did you read this?
https://winscp.net/eng/docs/message_timeout_external_console
_________________
Martin Prikryl
grvdutt

Guest


Yes sir, I already read the note, but I'm not invoking it from any program other than batch script

"Most commonly this happens when winscp.com has redirected output to a stream with limited buffer. If the stream is not being read from, the buffer gets eventually filled and winscp.com hangs, when trying to write into it. "

How can we increase the buffer?? Is there any way to resolve this.

Regards,
Gaurav
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25019
Location: Prague, Czechia
grvdutt wrote:
Yes sir, I already read the note, but I'm not invoking it from any program other than batch script

WinSCP may inherit the redirection from the batch file. How do you run the batch file?

Quote:
How can we increase the buffer?? Is there any way to resolve this.

Well that depends where and how (and if at all) you have the output redirected. But generally increasing the buffer size is not a solution. Solution is making sure the output is consumed continuously.
_________________
Martin Prikryl
zbl

Guest


hi,

tagging onto this thread.
i also have the same problem.

scenario. i'm using a batch script to execute winscp.com

SET /P FILENAME=What is the name of the file to download?
ECHO File to download is: %FILENAME%

c:\"Program Files (x86)"\winscp\winscp.com /passive=on /script="c:\simple.txt" /parameter // "%FILENAME%"

c:\"Program Files (x86)"\winscp\winscp.com /script="c:\yt_simple.txt" /parameter // "%FILENAME%"


usually at the second call of the winscp.com, i will hit this problem.

with regards to the script (simple.txt, yt_simple.txt), basically, this is what happens

option echo on
option confirm off
open a site defined in winscp
lcd "c:/"
get -resume %1%.ts / put -resume %1%.ts
bye
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25019
Location: Prague, Czechia
zbl wrote:
i also have the same problem.

The same question: How do you run the batch file?

Ntb, /passive=on specified on command-line won't get propagated to the script.

Last edited by martin on 2014-08-20; edited 1 time in total
zbl

Guest


Hi,

Thanks for the response.

The question as to how the script is being invoked?

I'm using windows machine. So I just open file explorer and double click on the batch file.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 25019
Location: Prague, Czechia
zbl wrote:
I'm using windows machine. So I just open file explorer and double click on the batch file.


Thanks for your response.

Please attach a full log file showing the problem (using the latest version of WinSCP).

To generate log file, use /log=path_to_log_file command-line argument. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
_________________
Martin Prikryl
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