[wpkg-users] silent installer for Divalto stalls

Rainer Meier r.meier at wpkg.org
Fri Jul 4 15:48:51 CEST 2014


Hi Vincent,

On 04.07.2014 09:47, Vincent Malien wrote:
> I did a silent installer for Divalto Infinity: http://wpkg.org/Divalto_infinity
> it started to work fine, but since I added a xcopy of 108 files, the script
> stalls on this line:
> <install cmd='xcopy /Y "%SOFTWARE%\Divalto\sys\*.*" c:\divalto\sys\*.*'/>
> This command woks fine direct from the shell.

You've been just trapped by Microsoft bug in WSH. If your commands send more 
than ~4kB of output to STDOUT and the buffer fills up, then Windows will stop 
the process until STDOUT is flushed. Though I spent a lot of time on potential 
workarounds of this issue but there is none. So you need to make sure your 
commands don't print that much on STDOUT.

Unfortunately xcopy is going to print really a lot of output by default which 
you won't see at all. So my recommendation is to redirect this output to NUL:


<install cmd='%COMSPEC% /c xcopy /Q /Y "%SOFTWARE%\Divalto\sys\*.*" 
c:\divalto\sys\*.* > NUL'/>

Caution: Didn't check or verify the command. But it should redirect its output 
to NUL (suppress it) and moreover also reduce the output by using /Q option.

Perhaps just adding /Q option would be sufficient even without redirect.


> In the FAQ, I found the topic 'My install command just stalls and never finishes
> ' which looks like my problem, so I changed the script like this:
> <install  timeout="1000" cmd='xcopy /Y "%SOFTWARE%\Divalto\sys\*.*"
> c:\divalto\sys\*.* >%TEMP%\install-log.txt 2>&1'/>


2>&1 is not adequate redirect to NUL. It will just append STDERR to STDOUT which 
will even print more to STDOUT. You need to redirect STDOUT to nul to suppress 
it, or use /Q argument of xcopy to reduce amount of data printed.

br,
Rainer



More information about the wpkg-users mailing list