Ioan,

Thanks for the detailed report (and solution).

I'm going to start a new thread to the devel list for discussion, but your 
solution sounds reasonable to me.

Lonnie


On Feb 16, 2010, at 5:29 AM, Ioan Indreias wrote:

> Hello,
> 
> We have conducted some tests on systems using Astlinux 0.7.0 and we found 
> that the limit for open files is set to 1024 (probably the default kernel 
> value).
> 
>     pbx load_tests # ulimit -n
>     1024
> 
> Because we had a machine which could process more than 130 calls 
> simultaneously we have reached to that limit:
> 
>     pbx load_tests # asterisk -rx "show channels" | grep "active calls"
>     0
>     pbx load_tests # ls -l /proc/$(cat /var/run/asterisk/asterisk.pid)/fd/ | 
> wc -l
>     23
> 
>     asterisk -rx "show channels" | grep "active calls"
>     130 active calls
>     pbx load_tests # ls -l /proc/$(cat /var/run/asterisk/asterisk.pid)/fd/ | 
> wc -l
>     1063
> 
> Each call is a SIP call between 2 extensions defined on the same Asterisk 
> server and the relation found between calls and open files is:
>     8 new open files at each new call
> 
> Each leg have one RX and one TX flow and each flow open 2 files (one pipe and 
> one stream) and this is how we explained the value found above
>     2 legs x 2 flows x 2 files = 8 open files per call
> 
> Thus we have modified the script which start asterisk (/etc/init.d/asterisk) 
> with the following configuration:
> 
>     ulimit -n 4096
> 
> and from that point our tests have not been affected by the errors reported 
> in the asterisk CLI.
> 
> Do you think is OK if you could add this configuration into the trunk (or at 
> least 2048) - or maybe the proposed change is considered inappropriately?
> 
> Best regards,
> Ioan Indreias
> 
> ------------------
>   if [ -r /etc/asterisk/extensions.conf ]; then
>     # Work around uclibc bug
>     ulimit -s unlimited
>     # Patch for open files error
>     ulimit -n 4096
>     asterisk -p -I
> ------------------
> 


------------------------------------------------------------------------------
SOLARIS 10 is the OS for Data Centers - provides features such as DTrace,
Predictive Self Healing and Award Winning ZFS. Get Solaris 10 NOW
http://p.sf.net/sfu/solaris-dev2dev
_______________________________________________
Astlinux-users mailing list
Astlinux-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/astlinux-users

Donations to support AstLinux are graciously accepted via PayPal to 
pay...@krisk.org.

Reply via email to