Difference between revisions of "CentOS 7.x Increase Inter Process Communication (IPC) limits"

From Notes_Wiki
(Created page with "<yambe:breadcrumb>CentOS_7.x_Inter_Process_Communication_IPC_settings|CentOS 7.x Inter Process Communication IPC settings</yambe:breadcrumb> =CentOS 7.x Increase Inter Process...")
 
m
 
Line 1: Line 1:
<yambe:breadcrumb>CentOS_7.x_Inter_Process_Communication_IPC_settings|CentOS 7.x Inter Process Communication IPC settings</yambe:breadcrumb>
[[Main Page|Home]] > [[CentOS]] > [[CentOS 7.x]] > [[CentOS 7.x system administration|System Administration]] > [[CentOS 7.x Inter Process Communication IPC settings|Inter Process Communication IPC settings]] > [[CentOS 7.x Increase Inter Process Communication (IPC) limits]]
=CentOS 7.x Increase Inter Process Communication (IPC) limits=


If increasing number of processes or threads or concurrency in an application is leading to application stability issues due to IPC limits.
If increasing number of processes or threads or concurrency in an application is leading to application stability issues due to IPC limits.
Line 37: Line 36:




<yambe:breadcrumb>CentOS_7.x_Inter_Process_Communication_IPC_settings|CentOS 7.x Inter Process Communication IPC settings</yambe:breadcrumb>
[[Main Page|Home]] > [[CentOS]] > [[CentOS 7.x]] > [[CentOS 7.x system administration|System Administration]] > [[CentOS 7.x Inter Process Communication IPC settings|Inter Process Communication IPC settings]] > [[CentOS 7.x Increase Inter Process Communication (IPC) limits]]

Latest revision as of 06:35, 25 August 2022

Home > CentOS > CentOS 7.x > System Administration > Inter Process Communication IPC settings > CentOS 7.x Increase Inter Process Communication (IPC) limits

If increasing number of processes or threads or concurrency in an application is leading to application stability issues due to IPC limits.

For example below logs indicate postgresql failing due to semaphore limit.

   < 2018-03-29 16:54:31.667 IST >FATAL:  could not create semaphores: No space left on device
   < 2018-03-29 16:54:31.667 IST >DETAIL:  Failed system call was semget(5432129, 17, 03600).
   < 2018-03-29 16:54:31.667 IST >HINT:  This error does *not* mean that you have run out of disk space.  It occurs when either the system limit for the maximum number of semaphore sets (SEMMNI), or the system wide maximum number of semaphores (SEMMNS), would be exceeded.  You need to raise the respective kernel parameter.  Alternatively, reduce PostgreSQL's consumption of semaphores by reducing its max_connections parameter.
    The PostgreSQL documentation contains more information about configuring your system for PostgreSQL.


Then we can edit '/etc/sysctl.conf' and append following values:

   #Example for a computer with 16GB of RAM:
   kernel.shmmni=4096
   kernel.shmmax=17179869184
   kernel.shmall=8388608
   #kernel.sem=<SEMMSL> <SEMMNS> <SEMOPM> <SEMMNI>
   kernel.sem=250 1024000 32 4096
   kernel.msgmni=16384
   kernel.msgmax=65536
   kernel.msgmnb=65536

followed by

   sysctl -p

so that the error gets resolved.


Refer:


Home > CentOS > CentOS 7.x > System Administration > Inter Process Communication IPC settings > CentOS 7.x Increase Inter Process Communication (IPC) limits