Maximum number of threads per process in Linux?

前端 未结 16 2828
轮回少年
轮回少年 2020-11-22 02:16

What is the maximum number of threads that can be created by a process under Linux?

How (if possible) can this value be modified?

16条回答
  •  失恋的感觉
    2020-11-22 02:46

    For anyone looking at this now, on systemd systems (in my case, specifically Ubuntu 16.04) there is another limit enforced by the cgroup pids.max parameter.

    This is set to 12,288 by default, and can be overriden in /etc/systemd/logind.conf

    Other advice still applies including pids_max, threads-max, max_maps_count, ulimits, etc.

提交回复
热议问题