3 communcation channels:

stdin, stdout, stderr

We use | to pipe information of one process to another

We can think of pipe as an anonymous file that residese between 2 processes.

One process writes bytes to the pipe, the other reads.

What data structure pipes use?

Are all pipes unidirectional / half-duplex, i.e. one way from one process to another?


#include <unistd.h>
int pipe( int fd[] ) // 0 for success, !0 for errors
fd is an array of file desc, fd[0] == reading end, fd[1] == writing end