NAME
sema — enable or disable System V IPC semaphores at boot time
VALUES
Allowed values
1 (on)
or
0 (off)
DESCRIPTION
The
sema
tunable is a "switch" designed to enable the entire System V (InterProcess
Communications package (IPC) semaphore subsystem.
It not only allows user access, but when disabled, no memory space will even be
reserved on system boot, and the System V IPC semaphore subsystem will be
totally removed.
However, the default state is enabled so the system exists after the first
cold install.
Considering the minimal impact for the default tunable values, a disabled
semaphore system will be the exception.
Overview
System V IPC is comprised of mechanisms for arbitrary processes to send and
receive data messages, share virtual address space and use semaphores
to synchronize execution.
A System V semaphore is a synchronization method for user processes to obtain
atomic access to common data and resources.
Each semaphore "set" has an ID, but each set can contain one or more
independent
sema()
system calls.
All operations are done atomically.
Either all semaphores are set or none will be set.
You determine whether the
sema()
system call will sleep or return with an error
should the requested operation fail.
Every semaphore set has an ID which is derived from a user-specified "key."
The two "operations" on a semaphore you can request are increment(>0)
and decrement(<0).
An increment adds
1
to a
sema,
and the kernel issues a wakeup on any processes sleeping on that
sema
(waiting for just such an increment).
A decrement subtracts
1
(if possible), but may sleep waiting for another process to increment the
sema.
A "binary" semaphore is simply the use of only
0
and
1
states for a semaphore.
A "counting" semaphore provides many processes to increment a single
semaphore, and represents a single resource with many waiting processes.
The choice is up to you.
The kernel does not decide this aspect.
Who Is Expected to Change This Tunable?
Anyone.
Restrictions on Changing
Changes to this tunable take effect at the next reboot.
What Are the Side Effects of Turning the Tunable Off?
Memory space will
not
be reserved on system boot, and the System V IPC semaphore subsystem will
be totally removed.
What Other Tunable Values Should Be Changed at the Same Time?
All the System V semaphore tunables are interrelated and should
not
be treated as independent variables.
The tunables must be evaluated as a system to ensure they
reflect the application requirements.
The
sema
tunables include
semaem,
semmap,
semmni,
semmns,
semmnu,
semmsl,
semume,
semvmx,
and
sysv_hash_locks.
WARNINGS
All HP-UX kernel tunable parameters are release specific.
This parameter may be removed or have its meaning changed in
future releases of HP-UX.
AUTHOR
sema
was developed by AT&T.
SEE ALSO
semaem(5),
semmap(5),
semmni(5),
semmns(5),
semmnu(5),
semmsl(5),
semume(5),
semvmx(5),
sysv_hash_locks(5).