I seem to have figured it out. Attached is a module with function executeCommand that executes a single command, gathers input, output and error code and returns it.<br>Comment at will.<br><br><br><div><span class="gmail_quote">
On 9/9/07, <b class="gmail_sendername">Konrads Smelkovs</b> &lt;<a href="mailto:konrads.smelkovs@gmail.com">konrads.smelkovs@gmail.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hello,<br><br>How to obtain the stderror?<br>chanel.SSHChannel has an interesting method extReceived, is it that?<div><span class="e" id="q_114ea2bf8c8f8daa_1"><br><br>On 9/8/07, <b class="gmail_sendername">Paul Swartz</b>
 &lt;<a href="mailto:paulswartz@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">paulswartz@gmail.com
</a>&gt; wrote:<div><span class="gmail_quote"></span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">On 9/8/07, Konrads Smelkovs &lt;<a href="mailto:konrads.smelkovs@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">

konrads.smelkovs@gmail.com</a>&gt; wrote:<br>&gt; 1) I want to invoke(exec) a command with arguments from a SSH Conch client.<br>&gt; The example suggests that arguments should be passed along with command, so<br>&gt; to invoke &#39;ls -l&#39;, one would pass 
common.NS(&#39;ls -l&#39;). What to do about<br>&gt; arguments that have spaces? Should I slash-escape them?<br><br>Commands are executed with the -e argument of your shell.&nbsp;&nbsp;You can<br>slash-escape spaces or quote them; either one should work.
<br><br>&gt; 2) How to obtain the retcode from an exec&#39;ed command?<br><br>If the server supports it, it sends a &#39;exit-status&#39; request to the<br>channel with a uint32 encoded exit code.&nbsp;&nbsp;If it exits with a signal,
<br>an &#39;exit-signal&#39; message is sent with format:<br>&nbsp;&nbsp;&nbsp;&nbsp;string signal name<br>&nbsp;&nbsp;&nbsp;&nbsp;bool core dumped<br>&nbsp;&nbsp;&nbsp;&nbsp;string error message<br>&nbsp;&nbsp;&nbsp;&nbsp;string language<br><br>HTH,<br>-p<br><br>_______________________________________________
<br>Twisted-Python mailing list<br><a href="mailto:Twisted-Python@twistedmatrix.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Twisted-Python@twistedmatrix.com</a><br><a href="http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python
</a><br></blockquote></div><br><br clear="all"><br></span></div><div><span class="e" id="q_114ea2bf8c8f8daa_2">-- <br>Konrads Smelkovs<br>Applied IT sorcery.
</span></div></blockquote></div><br><br clear="all"><br>-- <br>Konrads Smelkovs<br>Applied IT sorcery.