Questions tagged [ipc]

IPC stands for Inter-process Communication and represents a set of methods for exchanging data and messages between threads and processes.

In computing, Inter-process communication (IPC) is a set of methods for the exchange of data among multiple threads in one or more processes. Processes may be running on one or more computers connected by a network. IPC methods are divided into methods for:

  • message passing
  • synchronization
  • shared memory, and
  • remote procedure calls (RPC).

The method of IPC used may vary based on the bandwidth and latency of communication between the threads, and the type of data being communicated.

There are several reasons for providing an environment that allows process cooperation:

  • Information sharing
  • Speedup
  • Modularity
  • Convenience
  • Privilege separation

IPC may also be referred to as inter-thread communication and inter-application communication.

The combination of IPC with the address space concept is the foundation for address space independence/isolation.

4538 questions
20
votes
1 answer

How to communicate between php and boost library IPC?

I have client and server in php communicating over shared memory, Now I would like to access this shred memory object using Boost.Interprocess how can I access it? server.php: function create_image($str){ // Create a blank image and add some…
Arman
  • 4,566
  • 10
  • 45
  • 66
19
votes
2 answers

Lowest latency notification method between process under Linux

I'm looking for the lowest latency IPC that allow to put one process to sleep and allow other process to wake it. I'm looking for the lowest latency method. Some possible methods so far: Writing a byte to a pipe and reading it from it. Writing a…
Artyom
  • 31,019
  • 21
  • 127
  • 215
19
votes
3 answers

simple inter-process communication

I'm looking for a simple way to pass messages from one process (Perl script, short-lived) to another (Python script, long-running) - both processes local to the same machine. I've done some research, but what I've found was either over my head or…
AnC
  • 4,099
  • 8
  • 43
  • 69
19
votes
4 answers

IPC speed and compare

I am trying to implement a real-time application which involves IPC across different modules. The modules are doing some data intensive processing. I am using message queue as the backbone(Activemq) for IPC in the prototype, which is…
Lily
  • 5,872
  • 19
  • 56
  • 75
19
votes
2 answers

Communication between Windows Service and Desktop Application

I know that similar questions have been asked before, but even after all my Googling I'm still completely lost. I've written a small Windows Service that does what my main application used to do in a background thread (it made sense to move it to a…
Kyle G.
  • 870
  • 2
  • 10
  • 22
19
votes
4 answers

Linux C: upon receiving a signal, is it possible to know the PID of the sender?

Suppose my C program handles SIGUSR1. When it receives this signal, is it possible to know who sent it? I.e., How to get the pid of sender process?
daisy
  • 22,498
  • 29
  • 129
  • 265
18
votes
3 answers

AF_UNIX equivalent for Windows

I want to know how to use something that behaves like Unix Domain Socket on Windows. The behaviour is: A process will be a "server" and receive connections from other processes and it can keep and use connections from different processes, as a TCP…
Squall
  • 4,344
  • 7
  • 37
  • 46
18
votes
4 answers

How to use Zeromq's inproc and ipc transports?

Im a newbie to ZERMQ. ZeroMQ has TCP, INPROC and IPC transports. I'm looking for examples using python and inproc in Winx64 and python 2.7, which could also be used for linux. Also, I have been looking for UDP methods of transport and cant find…
Merlin
  • 24,552
  • 41
  • 131
  • 206
18
votes
4 answers

How to send integer with pipe between two processes!

I am trying to send an integer with pipe in a POSIX system but write() function is working for sending string or character data. Is there any way to send integer with a pipe? Regards
erogol
  • 13,156
  • 33
  • 101
  • 155
18
votes
4 answers

Shared Memory or mmap - Linux C/C++ IPC

The context is Inter-Process-Communication where one process("Server") has to send fixed-size structs to many listening processes("Clients") running on the same machine. I am very comfortable doing this in Socket Programming. To make the…
Humble Debugger
  • 4,439
  • 11
  • 39
  • 56
18
votes
7 answers

IPC (inter process communication) between python and java

First, a little explanation of why I'm asking this question in the first place: I'm writing a python program (with a wxPython gui) that needs to call a Java AWT program from python and extract data from it. I have an in-process working solution on…
Adam Fraser
  • 6,255
  • 10
  • 42
  • 54
18
votes
1 answer

Transfer InputStream to another Service (across process boundaries) with ParcelFileDescriptor.createPipe() failes with "EBADF (Bad file number)"

I want to "send" an InputStream from one Android Service to another service running within a different process by using ParcelFileDescriptor.createPipe(), a stream-to-stream copy thread and a ParcelFileDescriptor, representing the read side of the…
Flow
  • 23,572
  • 15
  • 99
  • 156
18
votes
9 answers

What is the easiest way to do inter-process communication (IPC) in C#?

I have two C# applications and I want one of them send two integers to the other one (this doesn't have to be fast since it's invoked only once every few seconds). What's the easiest way to do this? (It doesn't have to be the most elegant one.)
genesys
  • 201
  • 1
  • 3
  • 5
17
votes
2 answers

IPC shared memory across Python scripts in separate Docker containers

The Problem I have written a neural network classifier that takes in massive images (~1-3 GB apiece), patches them up, and passes the patches through the network individually. Training was going really slowly, so I benchmarked it and found that it…
Jacob Stern
  • 3,758
  • 3
  • 32
  • 54
17
votes
6 answers

communication between 2 browser windows in electron

I need to build an app that will span across multiple monitor screens, something like this: Electron supports multiple windows but how do I communicate between them?
AIon
  • 12,521
  • 10
  • 47
  • 73