Filesystems

Overview

A filesystem is a data storage service that allows applications to share mass storage.

File

A file is a data resource that can be written to or read from. This definition is intentionally very open-ended: in Linux, "everything is a file." Each file is associated with a file descriptor (FD), a unique integer associated with an open file. An FD is used as a handle to the given file.

Sockets

A socket is a bidirectional data channel used for communication between two processes (not necessarily on the same machine). They are described using standard Unix file descriptors. As such, a socket descriptor is a file descriptor that refers to a socket.

The socket syscall is used to create a new socket.

Pipes

A pipe is a unidirectional data channel used for interprocess communication. Like sockets, they are described using standard Unix file descriptors.

The pipe syscall is used to create a new pipe.

Powered by Forestry.md