Saturday, December 17, 2011

Linux IPC Mechanisms

Discuss the following IPC Mechanisms as implemented in LINUX
 
1.Signals
2.Pipes
3.Shared Memory
4.Message Queues
5.Sockets


2 comments:

  1. http://tldp.org/LDP/tlk/ipc/ipc.html
    http://tldp.org/LDP/lpg/node7.html

    Mainly used IPC mechanisms are Pipes,Signal & sockets.Also System V IPC mechanisms are Semaphores,Shared memory & message queues

    ReplyDelete
  2. Which is better Linux IPC---
    http://stackoverflow.com/questions/404604/comparing-unix-linux-ipc

    Shared memory can be the most efficient since you build your own communication scheme on top of it, but it requires a lot of care and synchronization. Solutions are available for distributing shared memory to other machines too.

    Pipe I/O is the fastest but needs a parent/child relationship to work.

    Sockets are the most portable these days, but require more overhead than pipes. The ability to transparently use sockets locally or over a network is a great bonus.

    Message queues and signals can be great for hard real-time applications, but they are not as flexible.

    These methods were naturally created for communication between processes, and using multiple threads within process can complicate things -- especially with signals.

    ReplyDelete