简体   繁体   English

意外的主管进程限制

[英]Unexpected supervisor processes limitation

I'm using Beanstalkd queues in Laravel, controlled by Supervisord.我在 Laravel 中使用 Beanstalkd 队列,由 Supervisord 控制。

  • Laravel v7.30.6 Laravel v7.30.6
  • Beanstalkd v1.10 Beanstalkd v1.10
  • Supervisord v3.3.1主管 v3.3.1
  • Ubuntu 18.04.6 LTS (125G RAM) Ubuntu 18.04.6 LTS(125G 内存)
  • PHP 7.4 PHP 7.4

I have 19 tubes (queues) and around 1000 processes in total.我总共有 19 个管(队列)和大约 1000 个进程。

When I run supervisor in Systemd mode ( service supervisor start ) I face with some processes limitation.当我在 Systemd 模式下运行 supervisor ( service supervisor start ) 时,我面临一些进程限制。 Supervisor runs only around 360 processes in total in some tubes, rest of tubes waits and doesn't run processes at all. Supervisor 在某些管中总共只运行了大约 360 个进程,rest 个管等待并且根本不运行进程。

beanstalk console example beanstalk 控制台示例

But when I run supervisor from command line from root ( /usr/bin/supervisord -c /etc/supervisor/supervisord.conf ) all processes in all tubes runs normally.但是,当我从根目录( /usr/bin/supervisord -c /etc/supervisor/supervisord.conf )的命令行运行主管时,所有管中的所有进程都正常运行。

So, why I have limitations in Systemd mode?那么,为什么我在 Systemd 模式下有限制?

PS: and of course I know about system ulimit, and I have increased limits for root and for user owned tubes processes. PS:当然我知道系统 ulimit,我已经增加了对 root 和用户拥有的管进程的限制。

ulimit -Hu: 655350 ulimit-胡:655350

ulimit -Su: 655350 ulimit-Su:655350

supervisord requires minfds parameter to increase open files limit for beanstalkd processes supervisord 需要minfds参数来增加 beantalkd 进程的打开文件限制

make sure this is set确保已设置

cat /etc/supervisord.conf
[supervisors]
...
minfds=1024;

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM