Increasing PID count

Learn how to increase the maximum number of threads (PID count).

About this task

The default PID count can be sufficient with nodes containing more than 12 Ceph OSDs, especially during recovery. As a result, some ceph-osd daemons can terminate and fail to start again. If this happens, increase the maximum possible number of threads allowed.

Temporarily increase the maximum number of threads

Temporarily increase the maximum number of threads.
sysctl -w kernel.pid.max=PID_COUNT
For example,
[root@mon ~]# sysctl -w kernel.pid.max=4194303

Permanently increase the maximum number of threads

Permanently increase the maximum number of threads by updating the /etc/sysctl.conf file.
For example,
[root@mon ~]# sysctl -w kernel.pid.max=4194303