1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372
|
.\" (c) 1993 by Thomas Koenig (ig25@rz.uni-karlsruhe.de)
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of this
.\" manual under the conditions for verbatim copying, provided that the
.\" entire resulting derived work is distributed under the terms of a
.\" permission notice identical to this one
.\"
.\" Since the Linux kernel and libraries are constantly changing, this
.\" manual page may be incorrect or out-of-date. The author(s) assume no
.\" responsibility for errors or omissions, or for damages resulting from
.\" the use of the information contained herein. The author(s) may not
.\" have taken the same level of care in the production of this manual,
.\" which is licensed free of charge, as they might when working
.\" professionally.
.\"
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.
.\" License.
.\" Modified Sun Jul 25 11:05:58 1993 by Rik Faith (faith@cs.unc.edu)
.\" Modified Sat Feb 10 16:18:03 1996 by Urs Thuermann (urs@isnogud.escape.de)
.\" Modified Mon Jun 16 20:02:00 1997 by Nicols Lichtmaier <nick@debian.org>
.\" Modified Mon Feb 6 16:41:00 1999 by Nicols Lichtmaier <nick@debian.org>
.\" Modified Tue Feb 8 16:46:45 2000 by Chris Pepper <pepper@tgg.com>
.TH HIER 7 "June 16, 1997" "Linux" "Linux Programmer's Manual"
.SH NAME
hier \- Description of the file system hierarchy
.SH DESCRIPTION
A typical Linux system has, among others, the following directories:
.TP
.I /
This is the root directory. This is where the whole tree starts.
.TP
.I /bin
This directory contains executable programs which are needed in
single user mode and to bring the system up or repair it.
.TP
.I /boot
Contains static files for the boot loader. This directory only holds
the files which are needed during the boot process. The map installer
and configuration files should go to
.I /sbin
and
.IR /etc .
.TP
.I /dev
Special or device files, which refer to physical devices. See
mknod(1).
.TP
.I /dos
If both MS\-DOS and Linux are run on one computer, this is a typical
place to mount a DOS file system.
.TP
.I /etc
Contains configuration files which are local to the machine. Some
larger software packages, like X11, can have their own subdirectories
below
.IR /etc .
Site-wide configuration files may be placed here or in
.IR /usr/etc .
Nevertheless, programs should always look for these files in
.I /etc
and you may have links for these files to
.IR /usr/etc .
.TP
.I /etc/skel
When a new user account is created, files from this directory are
usually copied into the user's home directory.
.TP
.I /etc/X11
Configuration files for the X11 window system.
.TP
.I /home
On machines with home directories for users, these are usually beneath
this directory, directly or not. The structure of this directory
depends on local admininstration decisions.
.TP
.I /lib
This directory should hold those shared libraries that are necessary
to boot the system and to run the commands in the root filesystem.
.TP
.I /mnt
is a mount point for temporarily mounted filesystems
.TP
.I /proc
This is a mount point for the
.I proc
filesystem, which provides information about running processes and
the kernel. This pseudo-file system is described in more detail in
.BR proc (5).
.TP
.I /sbin
Like
.IR /bin ,
this directory holds commands needed to boot the system, but which are
usually not executed by normal users.
.TP
.I /tmp
This directory contains temporary files which may be deleted with no
notice, such as by a regular job or at system boot up.
.TP
.I /usr
This directory is usually mounted from a seperate partition. It
should hold only sharable, read-only data, so that it can be mounted
by various machines running Linux.
.TP
.I /usr/X11R6
The X-\Window system, version 11 release 6.
.TP
.I /usr/X11R6/bin
Binaries which belong to the X\-Windows system; often, there is a
symbolic link from the more traditional
.I /usr/bin/X11
to here.
.TP
.I /usr/X11R6/lib
Data files associated with the X\-Windows system.
.TP
.I /usr/X11R6/lib/X11
These contain miscellaneous files needed to run X; Often, there is a
symbolic link from
.I /usr/lib/X11
to this directory.
.TP
.I /usr/X11R6/include/X11
Contains include files needed for compiling programs using the X11
window system. Often, there is a symbolic link from
.I /usr/inlcude/X11
to this directory.
.TP
.I /usr/bin
This is the primary directory for executable programs. Most programs
executed by normal users which are not needed for booting or for
repairing the system and which are not installed locally should be
placed in this directory.
.TP
.I /usr/bin/X11
is the traditional place to look for X11 executables; on Linux, it
usually is a symbolic link to
.IR /usr/X11R6/bin .
.TP
.I /usr/dict
This directory holds files containing word lists for spell checkers.
.TP
.I /usr/doc
You may find documentation about the installed software packages in this
directory.
.TP
.I /usr/etc
Site-wide configuration files to be shared between several machines
may be stored in this directory. However, commands should always
reference those files using the
.I /etc
directory. Links from files in
.I /etc
should point to the appropriate files in
.IR /usr/etc .
.TP
.I /usr/include
Include files for the C compiler.
.TP
.I /usr/include/X11
Include files for the C compiler and the X\-Windows system. This is
usually a symbolic link to
.I /usr/X11R6/include/X11.
.TP
.I /usr/include/asm
Include files which declare some assembler functions. This used to be a
symbolic link to
.IR /usr/src/linux/include/asm .
.TP
.I /usr/include/linux
This contains information which may change from system release to
system release and used to be a symbolic link to
.I /usr/src/linux/include/linux
to get at operating system specific information.
(Note that one should have include files there that work correctly with
the current libc and in user space. However, Linux kernel source is not
designed to be used with user programs and does not know anything
about the libc you are using. It is very likely that things will break
if you let
.I /usr/include/asm
and
.I /usr/include/linux
point at a random kernel tree. Debian systems don't do this
and use headers from a known good kernel
version, provided in the libc*-dev package.)
.TP
.I /usr/include/g++
Include files to use with the GNU C++ compiler.
.TP
.I /usr/lib
Object libraries, including dynamic libraries, plus some executables
which usually are not invoked directly. More complicated programs may
have whole subdirectories there.
.TP
.I /usr/lib/X11
The usual place for data files associated with X programs, and
configuration files for the X system itself. On Linux, it usually is
a symbolic link to
.IR /usr/X11R6/lib/X11 .
.TP
.I /usr/lib/gcc-lib
contains executables and include files for the GNU C compiler,
.BR gcc (1).
.TP
.I /usr/lib/groff
Files for the GNU groff document formatting system.
.TP
.I /usr/lib/uucp
Files for
.BR uucp (1).
.TP
.I /usr/lib/zoneinfo
Files for timezone information.
.TP
.I /usr/local
This is where programs which are local to the site typically go.
.TP
.I /usr/local/bin
Binaries for programs local to the site go there.
.TP
.I /usr/local/doc
Local documentation
.TP
.I /usr/local/etc
Configuration files associated with locally installed programs go there.
.TP
.I /usr/local/lib
Files associated with locally installed programs go there.
.TP
.I /usr/local/info
Info pages associated with locally installed programs go there.
.TP
.I /usr/local/man
Manpages associated with locally installed programs go there.
.TP
.I /usr/local/sbin
Locally installed programs for system admininstration.
.TP
.I /usr/local/src
Source code for locally installed software.
.TP
.I /usr/sbin
This directories contains program binaries for system admininstration
which are not essentail for the boot process, for mounting
.IR /usr ,
or for system repair.
.TP
.I /usr/share
This directory contains subdirectories with specific application data, that
can be shared among different architectures of the same OS.
.TP
.I /usr/share/doc
.TP
.I /usr/share/man
Manpages go in there, into their subdirectories.
.TP
.I /usr/share/man/<locale>/man[1-9]
These directories contain manual pages which are in source code form.
Systems which use a unique language and code set for all manual pages
may omit the
.I <locale>
substring.
.TP
.I /usr/src
Source files for different parts of the system, included with some packages
for reference purposes. Don't work here with your own projects, as files
below /usr should be read-only except when installing software.
.TP
.I /usr/src/linux
This has always been the traditional place where kernel sources were
unpacked. This was important on systems that /usr/include/linux was a
symlink here. You should probably use another directory for building the
kernel now.
.TP
.I /usr/tmp
Obsolete. This should be a link
to
.IR /var/tmp .
This link is present only for compatibility reasons and shouldn't be used.
.TP
.I /var
This directory contains files which may change in size, such as spool
and log files.
.TP
.I /var/adm
This directory is superseded by
.I /var/log
and should be a symbolic link to
.IR /var/log .
.TP
.I /var/backups
This directory is used to save backup copies of important system files.
.TP
.I /var/cache/man/cat[1-9]
These directories contain preformatted manual pages according to their
manpage section.
.TP
.I /var/lock
Lock files are placed in this directory. The naming convention for
device lock files is
.I LCK..<device>
where
.I <device>
is the device's name in the filesystem.
The format used is that of HDU UUCP lock files, i.e. lock files
contain a PID as a 10-byte ASCII decimal number, followed by a newline
character.
.TP
.I /var/log
Miscelanous log files.
.TP
.I /var/preserve
This is where
.BR vi (1)
saves edit sessions so they can be restored later.
.TP
.I /var/run
Run-time variable files, like files holding process identifiers (PIDs)
and logged user information
.IR (utmp) .
Files in this directory are usually cleared when the system boots.
.TP
.I /var/spool
Spooled (or queued) files for various programs.
.TP
.I /var/spool/at
Spooled jobs for
.BR at (1).
.TP
.I /var/spool/cron
Spooled jobs for
.BR cron (1).
.TP
.I /var/spool/lpd
Spooled files for printing.
.TP
.I /var/spool/mail
Users' mailboxes.
.TP
.I /var/spool/smail
Spooled files for the
.BR smail (1)
mail delivery program.
.TP
.I /var/spool/news
Spool directory for the news subsystem.
.TP
.I /var/spool/uucp
Spooled files for
.BR uucp (1).
.TP
.I /var/tmp
Like
.IR /tmp ,
this directory holds temporary files stored for an unspecified duration.
.SH "CONFORMS TO"
The Linux filesystem standard, Release 1.2
.SH BUGS
This list is not exhaustive; different systems may be configured
differently.
.SH "SEE ALSO"
.BR find (1),
.BR ln (1),
.BR mount (1),
.BR proc (5),
The Linux Filesystem Standard
|