ASTERISK CRASHED : Too many open files

Hello everybody

My asterisk crashed , and when I consulted the log file “full” I fond that there is many Warnings and Erros :


[2016-02-22 10:56:53] ERROR[13050] acl.c: Cannot create socket
[2016-02-22 10:56:53] ERROR[13050] acl.c: Cannot create socket
[2016-02-22 10:56:53] ERROR[13050] acl.c: Cannot create socket
[2016-02-22 10:56:53] ERROR[13050] acl.c: Cannot create socket
[2016-02-22 10:56:53] ERROR[13050] acl.c: Cannot create socket
[2016-02-22 10:56:53] ERROR[13050] acl.c: Cannot create socket

[2016-02-22 10:56:53] WARNING[2842][C-00002b3e] res_rtp_asterisk.c: Unable to allocate RTP socket: Too many open files
[2016-02-22 10:56:53] WARNING[2842][C-00002b3e] res_rtp_asterisk.c: Unable to allocate RTP socket: Too many open files
[2016-02-22 10:56:53] WARNING[2842][C-00002b3e] res_rtp_asterisk.c: Unable to allocate RTP socket: Too many open files
[2016-02-22 10:56:53] WARNING[2842][C-00002b3e] res_rtp_asterisk.c: Unable to allocate RTP socket: Too many open files

[2016-02-22 11:00:54] WARNING[13019] asterisk.c: Accept returned -1: Too many open files
[2016-02-22 11:00:54] WARNING[13019] asterisk.c: Accept returned -1: Too many open files
[2016-02-22 11:00:54] WARNING[13019] asterisk.c: Accept returned -1: Too many open files
[2016-02-22 11:00:54] WARNING[13019] asterisk.c: Accept returned -1: Too many open files
[2016-02-22 11:00:54] WARNING[13019] asterisk.c: Accept returned -1: Too many open files

Can you help me !!

The normal startup script on CentOS will set the maximum number of open files to be the highest number supported by the OS. Which OS are you using? How are you starting Asterisk? How many simultaneous calls are you trying to handle.

For further information, see http://www.cyberciti.biz/faq/linux-increase-the-maximum-number-of-open-files/