[asterisk-users] need examples of asterisk and mysql integration

Mike Trest - On Travel Mike at Trest.COM
Wed Apr 23 14:29:47 CDT 2008


At 02:58 PM 4/23/2008, you wrote:
Re performance hit.


I actually re-wrote one of my frequently used AGI in "C" and even set 
the STICKEY-BIT to avoid reloading the static text portions.

I noticed slightly lower disk activity level (but the perl file was 
probably in memory cache too).  So keeping it memory resident with 
stickey-bit probably was not really needed.  But I did see a drop in 
over-all memory usage.   Alas,  none of these  'savings' were big 
enough to matter.

I notice same performance level regards number of simultaneous calls 
- - - but that too was moderated by eternal load balancing 
distribution to multiple Asterisk gateways.

For a slightly different twist.  I re-designed the AGI to be only a 
message-passing function
that talked via SOCKET to a always running service.  I let that 
service do all the heavy lifting
DB work and the AGI itself only asked questions and got 
replies.   Again, no measurable difference in performance.

So, I summarize to say that with over 6,000+ simultaneous call on 60 
different Asterisk boxes, there was no difference in OPERATIONAL 
performance that the human operators could measure.   Since any one 
box was running a balanced distribution, the large peaks of inbound 
calls did cause a problem either.  The CPU cores (dual core Xeon) 
were seeing about the same utilization levels with lots of idle time 
left over.  Probably because I was using more lower cost boxes spread 
about the US rather than fewer large boxes with a greater number of 
calls per box.

As several folks have commented,  everyone should write your AGI in 
whatever language you feel is best for your long term support needs 
because that is where your real costs savings are to be 
found.    Getting a few more cycles from the CPU by squeezing the 
programming is not high on my list of priorities.

IMHO,  My suggestion to use perl AGI still stands as good advice on 
any current technology machine.

..mike..




More information about the asterisk-users mailing list