Home

namedFIFO

A namedFIFO, commonly called a named pipe, is a special file in Unix-like operating systems that represents a unidirectional data channel for interprocess communication. It exists as an ordinary file in the filesystem and can be accessed by unrelated processes via its path. Data written to a namedFIFO by one process can be read by another process in a first-in-first-out order, though the channel itself is not message-oriented; it is a byte stream.

A namedFIFO is created with the mkfifo command or the equivalent system call, which creates a special

When a process opens a namedFIFO, behavior depends on the end being opened. Opening for reading blocks

A namedFIFO remains in the filesystem after processes terminate, unless it is explicitly removed with unlink.

Common use cases include simple producer–consumer pipelines, decoupled components in a software system, and situations requiring

file
with
the
FIFO
type
and
assigns
permission
bits.
The
name
of
the
FIFO
serves
as
a
persistent
handle
in
the
filesystem,
allowing
processes
to
locate
and
use
it
by
path.
Permissions
control
which
users
or
groups
may
open
the
FIFO
for
reading
or
writing.
until
a
writer
opens,
and
opening
for
writing
blocks
until
a
reader
opens,
unless
non-blocking
mode
(O_NONBLOCK)
is
specified.
Once
data
flow
begins,
writes
append
to
the
FIFO’s
internal
buffer
and
reads
retrieve
data
in
the
same
order
it
was
written.
The
kernel
imposes
a
finite
pipe
buffer;
writers
block
when
the
buffer
is
full
and
readers
block
when
the
buffer
is
empty.
This
persistence
allows
decoupled
processes
to
coordinate
over
time.
Security
is
governed
by
standard
filesystem
permissions,
which
restrict
access
to
the
FIFO
file.
IPC
between
unrelated
processes.
Limitations
include
reliance
on
correct
synchronization
for
message
boundaries
and
the
potential
for
blocking
behavior
if
readers
or
writers
are
absent.