[asterisk-dev] Asterisk Open File Limit

Matt Florell astmattf at gmail.com
Tue Oct 17 17:00:49 MST 2006


Thanks for the notes. I'm more used to the
use-lots-of-cheap-servers-in-a-cluster approach and never had to deal
the issues of a large monolithic server in an Asterisk scenario
before.

As for the limit of 65536, does it every really go anywhere near that
high for you? I had 600 Asterisk channels with hundreds of AGI and
manager calls happening and I never broke 3600.

MATT---

On 10/17/06, Matthew J. Roth <mroth at imminc.com> wrote:
> Matt Florell wrote:
> > What is the default open file limit in Asterisk and where is it defined?
> Matt,
>
> You need to change the maximum number of open file descriptors available
> to a process via ulimit.  I make all ulimit changes in the init script
> AND limits.conf.  That way they're applied in both of the following
> scenarios:
>
> 1) Asterisk is started automatically at boot.
> 2) Asterisk is started manually from a login prompt after a crash or
> maintenance downtime.
>
> Increasing the maximum number of file descriptors can be done by adding
> the following lines to limits.conf (where <user> is the user you run
> Asterisk as):
>
> <user>   soft   nofile   65536
> <user>   hard   nofile   65536
>
> And adding the following line to Asterisk's init script (in your case
> 'start_asterisk_boot.pl'), immediately prior to starting Asterisk itself:
>
> ulimit -n 65536
>
> I've solved a good number of Asterisk scalability issues, so feel free
> to contact me off-list if you run into any more.
>
> Matthew Roth
> InterMedia Marketing Solutions
> Software Engineer and Systems Developer
>
>


More information about the asterisk-dev mailing list