<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Nov 26, 2013 at 2:18 PM, Marouene Lakhdhar <span dir="ltr"><<a href="mailto:marouene.lakhdhar@gmail.com" target="_blank">marouene.lakhdhar@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><span style="font-family:Arial,Helvetica,sans-serif;font-size:13px">Hi,</span><div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px">
<br>

</div><div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px">I'm facing a performance issue with os:cmd/1. it takes about 5 secs to return the result however if i execute the commande with cmd.exe, the reuslt will be immediately displayed.</div>


<div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px"><br></div><div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px">


I'm using erl5.10.3 under windows 7. </div><div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px"><br></div><div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px">


Could you please help me how to avoid the extra time  when usung os:cmd/1?</div><div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px"><br></div>
<div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px">

Thanks,</div><div style="margin:0px;padding:0px;border:0px none;vertical-align:baseline;font-family:Arial,Helvetica,sans-serif;font-size:13px">Marouene.  </div></div><br></blockquote><div><br></div><div>I just brought up a machine with ESysMan, coped over an any.cmd with "echo hello>hello.txt"  and executed the any.cmd file and it created a file hello.txt pretty much right after I executed it.<br>
<br></div><div>I do it like this:<br><br><a href="https://github.com/comptekki/esysman/blob/master/src/ecom.erl">https://github.com/comptekki/esysman/blob/master/src/ecom.erl</a><br><br></div><div>Just a simple call to os:cmd(...)<br>
<br></div><div>I also put<br><br>C:\Program Files\erl5.9.3.1\erts-5.9.3.1\bin<br><br></div><div>at beginning of the System Variables, Path variable.  It's hard to tell why yours is slow with no context of how you are using it.<br>
</div><div><br></div><div>-wes<br></div></div></div></div>