Open files: cannot modify limit: Operation not permitted

Dear all,

I am running Asterisk 1.8.9.2 …when I run service asterisk restart … I am facing:

[root@sip ~]# service asterisk restart
Stopping safe_asterisk: [ OK ]
Shutting down asterisk: [ OK ]
Starting asterisk: /usr/sbin/safe_asterisk: line 86: ulimit: open files: cannot modify limit: Operation not permitted
[ OK ]

[root@sip security]# ulimit -n
4096

my /etc/security/limits.conf as follow:

root soft nofile 4096
root hard nofile 8196
asterisk soft nofile 4096
asterisk hard nofile 8196

End of file

please help

Thanks & Regards

Remove the hard limits.

Hello,
thanks, there are 2 hard limits as below, can I just remove the “asterisk hard nofile 8196” …
I am just worry if I remove the root ones … I would facing another problem :smile:
need your advice

Thanks & Regards

=======
my /etc/security/limits.conf as follow:

root soft nofile 4096
root hard nofile 8196
asterisk soft nofile 4096
asterisk hard nofile 8196

Out of the box, the asterisk one would be irrelevant. I suspect you don’t have an out of the box Asterisk.

noted with thanks