Kbase 3246: ipcs & ipcrm: Checking active message q's,memory, semaphores
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  5/10/1998 |
|
ipcs & ipcrm: Checking active message q's,memory, semaphores
900815-sec01
INTRODUCTION:
=============
Running Interprocess Communication Facilities Status (IPCS) is a
valuable Unix operating system utility to use to analyze the status
of active interprocess communications facilities. This utility
provides the user with a snapshot of currently active message
queues, shared memory, and semaphores.
Running IPCRM removes a message queue, semaphore set, or shared
memory id.
WHY YOU NEED TO DO THIS:
========================
To evaulate system resources and to identify which shared memory
segment or semaphore set needs to be removed from the system.
PROCEDURAL APPROACH:
====================
Run 'ipcs' to get message queues, shared memory and semaphores
displayed to the terminal, 'ipcs -s' for semaphores, and 'ipcs -m'
for shared memory.
Once you identify the semaphore or shared memory ID you want to
delete, you either can remove the semaphore identifier from the
system and destroy the set of semaphores and data structures
associated with it('ipcrm -s ID'), or remove the shared memory
identifier from the system('ipcrm -m ID'). The shared memory segment
and data structures associated with it are destroyed after the last
detach.
HOW TO READ THE IPCS OUTPUT:
============================
By default the output is broken into 6 categories (other arguements
passed to IPCS will cause different categories to be displayed):
1. Type of facility (T):
========================
q -- message queue
m -- shared memory segment
s -- semaphore
2. ID:
======
The identifier for the facility entry.
3. Key:
=======
The key used as an arguement msgget(2), semget(2), or shmget(2)
to create the facility.
4. Mode:
========
The facility access modes and flags: the mode consists of 11
characters that are interpreted as follows:
The first 2 characters are:
R --- If a processis waiting on a msgrcv
S --- If aa process is waiting on a msgsnd
D --- If the associated shared memory segment has been
removed. It will disappear when the last process
attached to the segment detaches it.
- --- If the corresponding special flag is not set
The next 9 characters are allocted for permissions:
r --- If read permissions is granted
w --- If write permissions is granted
a --- If alter permissions is granted
- --- If the indicted permission is not granted
5. Owner:
=========
The login name of the owner of the facility entry
6. Group:
=========
The group name of the group of the owner of the facility entry
REFERENCES TO WRITTEN DOCUMENTATION:
====================================
Progress Software Technical Support Note # 3246