Appendix H. Important System Directories
Sysadmins and anyone else writing administrative scriptsshould be intimately familiar with the following systemdirectories.
/bin
Binaries (executables). Basic system programsand utilities (such as bash).
/usr/bin
More system binaries.
/usr/local/bin
Miscellaneous binaries local to the particular machine.
/sbin
System binaries. Basic system administrative programsand utilities (such as fsck).
/usr/sbin
More system administrative programs and utilities.
/etc
Et cetera. Systemwide configurationscripts.
Of particular interest are the/etc/fstab(filesystem table),/etc/mtab(mounted filesystem table), and the /etc/inittabfiles.
/etc/rc.d
Boot scripts, on Red Hat and derivative distributionsof Linux.
/usr/share/doc
Documentation for installed packages.
/usr/man
The systemwide manpages.
/dev
Device directory. Entries (but notmount points) for physical and virtual devices.See Chapter 27.
/proc
Process directory. Contains information and statisticsabout running processes and kernel parameters.See Chapter 27.
/sys
Systemwide device directory. Contains information andstatistics about device and device names. This is newlyadded to Linux with the 2.6.X kernels.
/mnt
Mount. Directory for mountinghard drive partitions, such as /mnt/dos, and physicaldevices. In newer Linux distros, the /mediadirectory has takenover as the preferred mount point for I/O devices.
/media
In newer Linux distros, the preferred mount point forI/O devices, such as CD ROMs or USB flash drives.
/var
Variable(changeable) systemfiles. This is a catchall "scratchpad"directory for data generated while a Linux/UNIX machineis running.
/var/log
Systemwide log files.
/var/spool/mail
User mail spool.
/lib
Systemwide library files.
/usr/lib
More systemwide library files.
/tmp
System temporary files.
/boot
System bootdirectory. The kernel,module links, system map, and boot manager reside here.
Altering files in this directory may result in anunbootable system.
Notes
Some early UNIX systems had a fast, small-capacity fixeddisk (containing /,the root partition), and a second drive whichwas larger, but slower (containing /usrand otherpartitions). The most frequently used programs andutilities therefore resided on the small-but-fastdrive, in /bin,and the others on the slower drive, in /usr/bin.
This likewise accounts for the split between/sbinand/usr/sbin,/liband /usr/lib, etc.