1752775 Members
5258 Online
108789 Solutions
New Discussion юеВ

Semaphores question....

 
SOLVED
Go to solution
Jonathan Caplette
Regular Advisor

Semaphores question....

Hi guys!

I've a HP-UX 10.20 box whose running Peoplesoft applications, and the developers experienced some problems with their program. In the doc of Peoplesoft they says to increase the UNIX semaphores to resolv the problem... My question is how can I increase the semaphores on my box and does I have to rebuild the kernel to do this???

And by the way, does anybody have some doc on what is the semaphores and how does it work??

Thanks!
Jonathan
8 REPLIES 8
John Poff
Honored Contributor
Solution

Re: Semaphores question....

Hello,

There is a kernel parameter that sets the maximum number of semaphores, 'semmns'. They probably want you to bump up that setting. On a 10.20 box running Oracle, I have it set at 4096. You'll have to relink the kernel and reboot.

JP
John Poff
Honored Contributor

Re: Semaphores question....

To answer the second part of your question, semaphores are used by processes for interprocess communication. They are used to coordinate access to shared data structures.

Here is a link to a white paper that might help:

http://us-support.external.hp.com/cki/bin/doc.pl/sid=2bb983ac0cd078e3f7/screen=ckiDisplayDocument?docId=200000045206304

JP
James R. Ferguson
Acclaimed Contributor

Re: Semaphores question....

Hi Jonathan:

The question of "what is a semaphore" came up recently. See here:

http://forums.itrc.hp.com/cm/QuestionAnswer/1,1150,0xef9ce7e60861d511abcd0090277a778c,00.html

For Kernel parameters, see:

http://docs.hp.com/hpux/onlinedocs/os/KCparams.OverviewAll.html

...JRF...
Sachin Patel
Honored Contributor

Re: Semaphores question....

Hi
Semaphores is shared memory objects.
you can increase that by using sam (easy way)
sam -> Kernel configuration -> configurable parameters ->
This are the values relate to semaphores

sema 1 1 Static N/A Enable Sys V Semaphores
semaem 16384 16384 Static N/A Max Value for Adjust on Exit Semaphores
semmap 2924 2924 Static N/A Max Number of Semaphore Map Entries
semmni 2922 2922 Static N/A Number of Semaphore Identifiers
semmns 5844 5844 Static N/A Max Number of Semaphores
semmnu 1457 1457 Static N/A Number of Semaphore Undo Structures
semume 64 64 Static N/A Semaphore Undo Entries Per Process
semvmx 32768 32768 Static N/A Semaphore Maximum Value

Sachin
Is photography a hobby or another way to spend $
Jonathan Caplette
Regular Advisor

Re: Semaphores question....

Another question, if I increase the Number of Max semaphores, should I increase the rest of semaphores thing.
Ravi_8
Honored Contributor

Re: Semaphores question....

Hi,
Not necessary to increase the other semaphore parameters. But look at doc given by pplsoft. which parameter they asked to increase(semmax,semmni,or semmin) just increase that parameter. after increasing the parameter you need to rebuild the kernel(after increasing the parameter system prompts you to reboot which then boots with modified kernel)
never give up
Tony Lowrie
Advisor

Re: Semaphores question....

It is easier to use sam to re-tune semmni & semmns. Consult your 3rd party apps people to confirm the values. If you need to see semaphore General Usage Do :

ipcs -sbp

This lists the Semaphore usage on your system Left Column is Semaphore Identifiers ID. If total number is Equal to semmni then you need to up the limit.

Far right column is Semaphores add these up and Total should not be greater than semmns.

This is a rough guide :-)
Life is like MTB - Ups and Downs - and Adrenalin
Jonathan Caplette
Regular Advisor

Re: Semaphores question....

Hi guys....

Thanks for the help... I will do my kernel update tomorrow... Hope that everything's gonna be find... :)

ciao!