Asterisk Ulimit

Home » Asterisk Tips » Asterisk Ulimit
Asterisk Tips No Comments

After re/starting Asterisk with a user other than root you might see this error:

"/usr/sbin/safe_asterisk: line 86: ulimit: open files: cannot modify limit: Operation not permitted"

,
even if you try to set the current ulimit to a higher level.

Edit your ‘/usr/sbin/safe_asterisk‘ and comment (put #) the line 86 and 102. Or you can also modify ‘/etc/sudoers‘ in order to to allow your user to call ulimit via sudo. The reason for this is that Asterisk will limit the number of open files it uses if you are not a super-user, to 32K (look at line 32). Anyways, it’s very likely that Linux will cut you off at lower number than that.