【问题标题】:Too many open files raised by supervisord?supervisord 提出的打开文件太多?
【发布时间】:2017-07-12 10:57:17
【问题描述】:

我使用wrk 来测试由ubuntu 16.04 上的主管管理的Web API 服务。有错误“打开的文件太多”,但我设置了系统配置

/etc/security/limits.conf
*           soft    nofile  65535
*           hard    nofile  65535

仍然有错误“打开的文件太多”

我发现 supervisord 属于 rootcat /proc/PID/limits

Max open files            1024                 4096                 files

所以,将根限制设置添加到limits.conf,如下所示

root        soft    nofile  65535
root        hard    nofile  65535

重启 supervisord 后生效(cat /proc/PID/limits,得到 65535) 但supervisord很快退出,并以1024的限制自动启动。

Jul 12 18:55:53 adhost supervisord[10866]: Error: Another program is already listening on a port that one of our HTTP servers is configured to use.  Shut this program down first before starting supervisord.
Jul 12 18:55:53 adhost supervisord[10866]: For help, use /usr/bin/supervisord -h
Jul 12 18:55:53 adhost systemd[1]: supervisor.service: Main process exited, code=exited, status=2/INVALIDARGUMENT
Jul 12 18:55:53 adhost supervisorctl[10871]: Shut down

参考:ubuntu - too many open files?

【问题讨论】:

  • 这似乎与打开文件限制无关?看起来服务已经在运行了?
  • 感谢您的好意@RamanSailopal

标签: linux supervisord


【解决方案1】:

我通过sudo supervisorctl shutdown解决了不应该直接杀死P

【讨论】:

    猜你喜欢
    • 2015-08-14
    • 2013-10-15
    • 1970-01-01
    • 2019-09-17
    • 2012-05-09
    • 2011-07-18
    • 2019-10-30
    • 2011-01-03
    相关资源
    最近更新 更多