This article will be permanently flagged as inappropriate and made unaccessible to everyone. Are you certain this article is inappropriate? Excessive Violence Sexual Content Political / Social
Email Address:
Article Id: WHEBN0023453203 Reproduction Date:
In Unix and operating systems inspired by it, the file system is considered a central component of the operating system.[1] It was also one of the first parts of the system to be designed and implemented by Ken Thompson in 1969.[2]
Like in other operating systems, the filesystem provides information storage and retrieval, as well as interprocess communication, in the sense that the many small programs that traditionally comprise a Unix system can store information in files so that other programs can read these, although pipes complemented it in this role starting with the Third Edition. Additionally, the filesystem provides access to other resources through so-called device files that are entry points to terminals, printers, and mice.
The rest of this article uses "Unix" as a generic name to refer to both the original Unix operating system as well as its many workalikes.
The filesystem appears as a single rooted tree of directories.[3] Instead of addressing separate volumes such as disk partitions, removable media, and network shares as separate trees (as done in MS-DOS and Windows: each "drive" has a drive letter that denotes the root of its file system tree), such volumes can be "mounted" on a directory, causing the volume's file system tree to appear as that directory in the larger tree.[3] The root of the entire tree is denoted /.
/
In the original Bell Labs Unix, a two-disk setup was customary, where the first disk contained startup programs, while the second contained users' files and programs. This second disk was mounted at the empty directory named usr on the first disk, causing the two disks to appear as one filesystem, with the second's disks contents viewable at /usr.
usr
/usr
Unix directories do not "contain" files. Instead, they contain the names of files paired with references to so-called inodes, which in turn contain both the file and its metadata (owner, permissions, time of last access, etc., but no name). Multiple names in the file system may refer to the same file, a feature known as (hard) linking.[3] If this feature is taken into account, the file system is a limited type of directed acyclic graph, although the directories still form a tree, as they may typically not be hard-linked. (As originally envisioned in 1969, the Unix file system would in fact be used as a general graph with hard links to directories providing navigation, instead of path names.[2])
The original Unix file system supported three types of files: ordinary files, directories, and "special files", also known as device files.[3] The Berkeley Software Distribution (BSD) and System V each added a file type to be used for interprocess communication: BSD added sockets,[4] while System V added FIFO files.
BSD also added symbolic links to the range of file types, which are files that refer to other files, and complement hard links.[4] Other Unix systems may support additional types of files.[5]
Certain conventions exist for locating particular kinds of files, such as programs, system configuration files and users' home directories. These were first documented in the hier(7) man page since Version 7 Unix;[6] subsequent versions, derivatives and clones typically have a similar man page.[7][8][9][10][11]
hier(7)
The details of the directory layout have varied over time. Although the file system layout is not part of the Single UNIX Specification, several attempts exist to standardize it, such as the Linux Foundation's Filesystem Hierarchy Standard (FHS).
/bin
ls
cp
/usr/bin
/boot
/dev
/etc
init
/sbin
/home
/Users
/u
/usr/home
/lib
/lib32
/lib64
/media
/mnt
/opt
/proc
/root
/srv
/sys
/usr/src/sys
/tmp
/unix
/vmunix
/include
#include
/libexec
/usr/lib
/local
/usr/local/lib
/usr/local/bin
/share
man
/var
/log
/mail
root
/var/spool/mail
/spool
Linux, Unix, Berkeley Software Distribution, Sun Microsystems, Usenet
OpenBSD, Linux, NetBSD, Apple Inc., Berkeley Software Distribution
Linux, Gnu, C (programming language), Berkeley Software Distribution, Os X
Unix, UNIX System V, Linux, Berkeley Software Distribution, Bell Labs
Linux, Metadata, Microsoft Windows, Ntfs, Unicode
Computer science, Microsoft Office, Weak reference, .NET Framework, Ios