2012/11/20 13:05:10 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:10 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:11 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:11 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:12 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:12 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:13 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:13 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:14 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:14 [crit] 16779#0: accept4() failed (24: Too many open files) 2012/11/20 13:05:15 [crit] 16779#0: accept4() failed (24: Too many open files)
看起来是受到了系统对进程能够打开的最大文件数量限制,accept4系统调用无法获取新的文件描述符。可以使用ulimit -n来修改这个限制。
ulimit命令的修改在重启后会失效。对于不同的linux发行版,这个初始值是放在不同的配置文件中的,详情参考Google。
欢迎来到随意问技术百科, 这是一个面向专业开发者的IT问答网站,提供途径助开发者查找IT技术方案,解决程序bug和网站运维难题等。 温馨提示:本网站禁止用户发布与IT技术无关的、粗浅的、毫无意义的或者违法国家法规的等不合理内容,谢谢支持。