update and correct nits
[unix-history] / usr / src / sbin / fsck / SMM.doc / 0.t
CommitLineData
e0abcc58 1.\" Copyright (c) 1986 Regents of the University of California.
a38b2411
KM
2.\" All rights reserved. The Berkeley software License Agreement
3.\" specifies the terms and conditions for redistribution.
4.\"
e0abcc58 5.\" @(#)0.t 4.3 (Berkeley) %G%
a38b2411
KM
6.\"
7.if n .ND
8.TL
9Fsck \- The UNIX\(dg File System Check Program
e0abcc58
KD
10.EH 'SMM:5-%''The \s-2UNIX\s+2 File System Check Program'
11.OH 'The \s-2UNIX\s+2 File System Check Program''SMM:5-%'
a38b2411
KM
12.AU
13Marshall Kirk McKusick
14.AI
15Computer Systems Research Group
16Computer Science Division
17Department of Electrical Engineering and Computer Science
18University of California, Berkeley
19Berkeley, CA 94720
20.AU
21T. J. Kowalski
22.AI
23Bell Laboratories
24Murray Hill, New Jersey 07974
25.AB
26.FS
27\(dgUNIX is a trademark of Bell Laboratories.
28.FE
29.FS
30This work was done under grants from
31the National Science Foundation under grant MCS80-05144,
32and the Defense Advance Research Projects Agency (DoD) under
33Arpa Order No. 4031 monitored by Naval Electronic System Command under
34Contract No. N00039-82-C-0235.
35.FE
36This document reflects the use of
37.I fsck
6a1194d8 38with the 4.2BSD and 4.3BSD file system organization. This
a38b2411
KM
39is a revision of the
40original paper written by
41T. J. Kowalski.
42.PP
43File System Check Program (\fIfsck\fR)
44is an interactive file system check and repair program.
45.I Fsck
46uses the redundant structural information in the
47UNIX file system to perform several consistency checks.
48If an inconsistency is detected, it is reported
49to the operator, who may elect to fix or ignore
50each inconsistency.
51These inconsistencies result from the permanent interruption
52of the file system updates, which are performed every
53time a file is modified.
54Unless there has been a hardware failure,
55.I fsck
56is able to repair corrupted file systems
57using procedures based upon the order in which UNIX honors
58these file system update requests.
59.PP
60The purpose of this document is to describe the normal updating
61of the file system,
62to discuss the possible causes of file system corruption,
63and to present the corrective actions implemented
64by
65.I fsck.
66Both the program and the interaction between the
67program and the operator are described.
e0abcc58
KD
68.sp 2
69.LP
70Revised July 16, 1985
a38b2411
KM
71.AE
72.LP
e0abcc58 73.bp
a38b2411
KM
74.ce
75.B "TABLE OF CONTENTS"
76.LP
77.sp 1
78.nf
79.B "1. Introduction"
80.LP
81.sp .5v
82.nf
83.B "2. Overview of the file system
e0abcc58
KD
842.1. Superblock
852.2. Summary Information
862.3. Cylinder groups
872.4. Fragments
882.5. Updates to the file system
a38b2411
KM
89.LP
90.sp .5v
91.nf
92.B "3. Fixing corrupted file systems
e0abcc58
KD
933.1. Detecting and correcting corruption
943.2. Super block checking
953.3. Free block checking
963.4. Checking the inode state
973.5. Inode links
983.6. Inode data size
993.7. Checking the data associated with an inode
1003.8. File system connectivity
a38b2411
KM
101.LP
102.sp .5v
103.nf
104.B Acknowledgements
105.LP
106.sp .5v
107.nf
108.B References
109.LP
110.sp .5v
111.nf
112.B "4. Appendix A
e0abcc58
KD
1134.1. Conventions
1144.2. Initialization
1154.3. Phase 1 - Check Blocks and Sizes
1164.4. Phase 1b - Rescan for more Dups
1174.5. Phase 2 - Check Pathnames
1184.6. Phase 3 - Check Connectivity
1194.7. Phase 4 - Check Reference Counts
1204.8. Phase 5 - Check Cyl groups
1214.9. Cleanup
a38b2411 122.ds RH Introduction
e0abcc58 123.bp