Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

On kernel.sem tuning of linux system

2025-04-03 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Cat / proc/sys/kernel/sem

250 32000 32 128

Or

Ipcs-ls

-Semaphore Limits-

Max number of arrays = 128,

Max semaphores per array = 250

Max semaphores system wide = 32000

Max ops per semop call = 32

Semaphore max value = 32767

The signal queue arrays on my machine

Ipcs-a | wc-l

one hundred and forty four

I don't understand why it exceeded 144128, but my openmanage plugin has been timed out, and it can't be started or stopped. It took me a long time to check this problem for real TM.

First of all, the significance of the four parameters of kernel.sem is introduced.

Cat / proc/sys/kernel/sem

250 32000 32 128

250 SEMMSL max semaphores per array signal set holds the maximum number of signals

32000 maximum number of all signals in SEMMNS max semaphores system wide

32 SEMOPM max ops per semop call calls the maximum number of signals in a single signal set

Maximum value of 128 SEMMNI max number of arrays signal set

First

Max semaphores per array

Max number of arrays

These two parameters are definitely not enough. Let's raise them a little higher first.

Echo "641280 641280" > / proc/sys/kernel/sem

We use

Ipcs-a | grep nagios | wc-l

90 View the number of current nagios user signals

And get rid of it all.

Ipcs-a | grep nagios | awk'{print $2}'| xargs-N1 ipcrm-s there are a lot of explanations about ipcs and ipcrm commands on the Internet, so I won't say any more.

Ipcs-a | grep nagios | wc-l

After cleaning it all up, restart the application, such as

/ opt/dell/srvadmin/sbin/srvadmin-services.sh stop

Ipcs usage

Ipcs-an is the default output that prints information about all interprocess communication modes in the current system.

Ipcs-m prints out information about interprocess communication using shared memory.

Ipcs-Q prints out information about interprocess communication using message queuing.

Ipcs-s prints out information that uses signals for interprocess communication.

Detailed change time of ipcs-t output information

Ipcs-p output process ID in ipc mode

Creator / owner of ipcs-c output ipc mode

Ipcs-u outputs the status information of various ways of ipc under the current system (shared memory, message queue, signal)

Ipcrm usage

-m SharedMemory id deletes the shared memory identity SharedMemoryID. Shared memory segments and data structures associated with SharedMemoryID are deleted after the last detach operation.

-M SharedMemoryKey removes the shared memory identity created with the keyword SharedMemoryKey. The associated shared memory segments and data structure segments are deleted after the last detach operation.

-Q MessageID removes the message queuing identity MessageID and the message queuing and data structures associated with it.

-Q MessageKey deletes the message queue identity created by the keyword MessageKey and the message queue and data structures associated with it.

-s SemaphoreID deletes the semaphore identification SemaphoreID and its associated semaphore set and data structure.

S SemaphoreKey deletes the signal identity created by the keyword SemaphoreKey and the semaphore sets and data structures associated with it.

Ipcrm-m 18602

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report