14 Dec 2019

  • December 14, 2019
  • Amitraj
Interprocess Communication

• Like UNIX, Linux informs processes that an event has occurred
via signals.

• There is a limited number of signals, and they cannot carry
information: Only the fact that a signal occurred is available to
a process.

• The Linux kernel does not use signals to communicate with
processes with are running in kernel mode, rather,
communication within the kernel is accomplished via
scheduling states and wait queue structures.



Passing Data between Processes

• The pipe mechanism allows a child process to inherit a
communication channel to its parent; data written to one end of
the pipe can be read at the other.

• Shared memory offers an extremely fast way of
communicating; any data written by one process to a shared
memory region can be read immediately by any other process
that has mapped that region into its address space.

• To obtain synchronization, however, shared memory must be
used in conjunction with another interprocess-communication
mechanism.



Shared Memory Object

• The shared-memory object acts as a backing store for
shared-memory regions in the same way as a file can act as
backing store for a memory-mapped memory region.

• Shared-memory mappings direct page faults to map in pages
from a persistent shared-memory object.

• Shared-memory objects remember their contents even if no
processes are currently mapping them into virtual memory.

Translate

Popular Posts