<br><br><div class="gmail_quote">On Wed, Dec 10, 2008 at 8:02 PM, Suchindra Sandhu <span dir="ltr">&lt;<a href="mailto:suchindra@gmail.com">suchindra@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi Alessio,<br>
<br>
If you have many machines, then running commands via a shell script<br>
for loop quickly gets un-weildly. Especially since some machines could<br>
be slow in responding since they could be busy, faroff etc or it your<br>
command itself takes a long time to complete.<br>
<br>
Doing this in twisted will not only give you better resource<br>
allocation, but it will also be easier to get timeouts and such<br>
things. The twisted ssh implementation probably gives you other things<br>
as well, but I am not aware of them.<br>
<br>
Hope that helps.</blockquote><div><br>Hi,<br><br>yes this confirm my &quot;feeling&quot;. The fact is that I don&#39;t know if in Twisted I can easily do ssh proxying, as I use to do now configuring&nbsp; my .ssh/ssh_config file.. That&#39;s why for simplicity I fell back to plain scripts calling ssh. <br>
<br>But I would like to switch to Twisted for the aforementioned reasons.<br><br>Thanks.<br>--<br>Alessio Pace<br><br>&nbsp;</div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
<br>
--<br>
/s<br>
<div><div></div><div class="Wj3C7c"><br>
On Tue, Dec 9, 2008 at 3:55 AM, Alessio Pace &lt;<a href="mailto:alessio.pace@gmail.com">alessio.pace@gmail.com</a>&gt; wrote:<br>
&gt; Hi,<br>
&gt;<br>
&gt; I have to run commands and (later in time) collect logs from many machines,<br>
&gt; connecting through SSH.<br>
&gt;<br>
&gt; I was _genuinely_ wondering what an SSH client written in Twisted could give<br>
&gt; me more than executing plain old shell scripts in a for loop.<br>
&gt;<br>
&gt; From what I saw, given the fact that my run/collect commands remain still<br>
&gt; shell commands (cp, tar, etc...), the only thing that may change is that<br>
&gt; using Twisted I could have a better utilization of resources rather than a<br>
&gt; simple shell for loop in which I iterate in order over all the machines on<br>
&gt; which I have to issue commands.<br>
&gt;<br>
&gt; Am I missing something? I would like to stress the fact that I&#39;m asking this<br>
&gt; as a very specific question for Twisted usage in the context of<br>
&gt; running/retrieving results on remote machines (as indeed I already happily<br>
&gt; use Twisted for running custom network protocols) and I would right to<br>
&gt; choose a simple but effective solution for this case.<br>
&gt;<br>
&gt; Thanks in advance,<br>
&gt; Alessio Pace.<br>
&gt;<br>
</div></div>&gt; _______________________________________________<br>
&gt; Twisted-Python mailing list<br>
&gt; <a href="mailto:Twisted-Python@twistedmatrix.com">Twisted-Python@twistedmatrix.com</a><br>
&gt; <a href="http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python" target="_blank">http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python</a><br>
&gt;<br>
&gt;<br>
<br>
_______________________________________________<br>
Twisted-Python mailing list<br>
<a href="mailto:Twisted-Python@twistedmatrix.com">Twisted-Python@twistedmatrix.com</a><br>
<a href="http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python" target="_blank">http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python</a><br>
</blockquote></div><br>