Next | Prev | Up | Top | Contents | Index

IPC Parameters

The IPC tunable parameters set interprocess communication (IPC) structures. These structures include IPC messages, specified in /var/sysgen/mtune/msg; IPC semaphores, specified in /var/sysgen/mtune/sem; and IPC shared memory, specified in /var/sysgen/mtune/shm.

If IPC (interprocess communication) structures are incorrectly set, certain system calls will fail and return errors.

Before increasing the size of an IPC parameter, investigate the problem by using ipcs(1) to see if the IPC resources are being removed when no longer needed. For example, shmget returns the error ENOSPC if applications do not remove semaphores, memory segments, or message queues.

Note that IPC objects differ from most IRIX objects in that they are not automatically freed when all active references to them are gone. In particular, they are not deallocated when the program that created them exits.

Table A-1 lists error messages, system calls that cause the error, and parameters to adjust. Subsequent paragraphs explain the details you need to know before you increase the parameters listed in this table.

System Call Errors and IPC Parameters to Adjust
MessageSystem CallParameter
EAGAINmsgsnd()see below
EINVALmsgsnd()
shmget()
msgmax
shmmax
EMFILE shmat()sshmseg
ENOSPCsemget()
shmget()
msgmni
semmni, semmns,
shmmni

EAGAIN

If IPC_NOWAIT is set, msgsnd can return EAGAIN for a number of reasons:

EINVAL

shmget (which gets a new shared memory segment identifier) will fail with EINVAL if the given size is not within shmmin and shmmax. Since shmmin is set to the lowest possible value (1), and shmmax is very large, it should not be necessary to change these values.

EMFILE

shmat will return EMFILE if it attaches more than sshmseg shared memory segments. sshmseg is the total number of system-shared memory segments per process.

ENOSPC

shmget will return ENOSPC if:


Next | Prev | Up | Top | Contents | Index