<div dir="ltr"><div class="gmail_default" style="color:rgb(102,0,0)">How much Asterisk is affected depends on both how often you run a command, and even more significantly, what command you run (and which version of Asterisk).</div>
<div class="gmail_default" style="color:rgb(102,0,0)"><br></div><div class="gmail_default" style="color:rgb(102,0,0)">Commands that display information about every active channel, for example "sip show peers", may slow other processing significantly because they have to briefly lock the data structures to insure valid information.  There have been improvements in more recent versions of Asterisk that reduce the negative affects of this by looking at cached information instead of locking everything.</div>
<div class="gmail_default" style="color:rgb(102,0,0)"><br></div><div class="gmail_default" style="color:rgb(102,0,0)">On the other hand, requesting specific information (sip show peer X) or more generic information (sip show inuse) will have much less affect on other activity in Asterisk.</div>
<div class="gmail_default" style="color:rgb(102,0,0)"><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Apr 24, 2014 at 5:20 AM, Mikael Fredin <span dir="ltr"><<a href="mailto:mikael@wiraya.com" target="_blank">mikael@wiraya.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Just like the subject sais - how expensive is it to execute a lot of these commands to keep track of different things in asterisk?<br>
<br></div>I have avoided doing this because it feels a bit like a risk to spam the asterisk CLI this way, but is it really?<br>
<br></div>CPU-wise it doesn't seem very expensive to do it 100 times a second (from a simple test I did), but is it possible it will affect the asterisk service in any other negative way?<br><br></div>Regards,<br>Mikael<br>

</div>
<br>--<br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
               <a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
   <a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr">
<img alt="Digium logo" src="https://my.digium.com/images/graphics/digium_RGB_signature.gif" width="288" height="50" style="color:rgb(0,0,0);font-family:Arial,Helvetica,sans-serif;font-size:12px"><div>Scott Griepentrog<br>
Digium, Inc · Software Developer<br>445 Jan Davis Drive NW · Huntsville, AL 35806 · US<br>direct/fax: +1 256 428 6239 · mobile: +1 317 507 4029<br>Check us out at: <a href="http://digium.com" target="_blank">http://digium.com</a> · <a href="http://asterisk.org" target="_blank">http://asterisk.org</a><br>
</div></div>
</div>