version distributed with 4.2BSD
[unix-history] / usr / src / sbin / fsck / SMM.doc / 4.t
CommitLineData
a38b2411
KM
1.\" Copyright (c) 1982 Regents of the University of California.
2.\" All rights reserved. The Berkeley software License Agreement
3.\" specifies the terms and conditions for redistribution.
4.\"
5.\" @(#)4.t 4.1 (Berkeley) %G%
6.\"
7.ds RH Appendix A \- Fsck Error Conditions
8.NH
9Appendix A \- Fsck Error Conditions
10.NH 2
11Conventions
12.PP
13.I Fsck
14is
15a multi-pass file system check program.
16Each file system pass invokes a different Phase of the
17.I fsck
18program.
19After the initial setup,
20.I fsck
21performs successive Phases over each file system,
22checking blocks and sizes,
23path-names,
24connectivity,
25reference counts,
26and the map of free blocks,
27(possibly rebuilding it),
28and performs some cleanup.
29.LP
30Normally
31.I fsck
32is run non-interactively to
33.I preen
34the file systems after an unclean halt.
35While preen'ing a file system,
36it will only fix corruptions that are expected
37to occur from an unclean halt.
38These actions are a proper subset of the actions that
39.I fsck
40will take when it is running interactively.
41Throughout this appendix many errors have several options
42that the operator can take.
43When an inconsistency is detected,
44.I fsck
45reports the error condition to the operator.
46If a response is required,
47.I fsck
48prints a prompt message and
49waits for a response.
50When preen'ing most errors are fatal.
51For those that are expected,
52the response taken is noted.
53This appendix explains the meaning of each error condition,
54the possible responses, and the related error conditions.
55.LP
56The error conditions are organized by the
57.I Phase
58of the
59.I fsck
60program in which they can occur.
61The error conditions that may occur
62in more than one Phase
63will be discussed in initialization.
64.NH 2
65Initialization
66.PP
67Before a file system check can be performed, certain
68tables have to be set up and certain files opened.
69This section concerns itself with the opening of files and
70the initialization of tables.
71This section lists error conditions resulting from
72command line options,
73memory requests,
74opening of files,
75status of files,
76file system size checks,
77and creation of the scratch file.
78All of the initialization errors are fatal
79when the file system is being preen'ed.
80.sp
81.LP
82.B "\fIC\fP option?"
83.br
84\fIC\fP is not a legal option to
85.I fsck ;
86legal options are \-b, \-y, \-n, and \-p.
87.I Fsck
88terminates on this error condition.
89See the
90.I fsck (8)
91manual entry for further detail.
92.sp
93.LP
94.B "cannot alloc NNN bytes for blockmap"
95.br
96.B "cannot alloc NNN bytes for freemap"
97.br
98.B "cannot alloc NNN bytes for statemap"
99.br
100.B "cannot alloc NNN bytes for lncntp"
101.br
102.I Fsck 's
103request for memory for its virtual
104memory tables failed.
105This should never happen.
106.I Fsck
107terminates on this error condition.
108See a guru.
109.sp
110.LP
111.B "Can't open checklist file: \fIF\fP"
112.br
113The file system checklist file
114\fIF\fP (usually
115.I /etc/fstab )
116can not be opened for reading.
117.I Fsck
118terminates on this error condition.
119Check access modes of \fIF\fP.
120.sp
121.LP
122.B "Can't stat root"
123.br
124.I Fsck 's
125request for statistics about the root directory ``/'' failed.
126This should never happen.
127.I Fsck
128terminates on this error condition.
129See a guru.
130.sp
131.LP
132.B "Can't stat \fIF\fP"
133.br
134.B "Can't make sense out of name \fIF\fP"
135.br
136.I Fsck 's
137request for statistics about the file system \fIF\fP failed.
138When running manually,
139it ignores this file system
140and continues checking the next file system given.
141Check access modes of \fIF\fP.
142.sp
143.LP
144.B "Can't open \fIF\fP"
145.br
146.I Fsck 's
147request attempt to open the file system \fIF\fP failed.
148When running manually, it ignores this file system
149and continues checking the next file system given.
150Check access modes of \fIF\fP.
151.sp
152.LP
153.B "\fIF\fP: (NO WRITE)"
154.br
155Either the \-n flag was specified or
156.I fsck 's
157attempt to open the file system \fIF\fP for writing failed.
158When running manually,
159all the diagnostics are printed out,
160but no modifications are attempted to fix them.
161.sp
162.LP
163.B "file is not a block or character device; OK"
164.br
165You have given
166.I fsck
167a regular file name by mistake.
168Check the type of the file specified.
169.LP
170Possible responses to the OK prompt are:
171.IP YES
172Ignore this error condition.
173.IP NO
174ignore this file system and continues checking
175the next file system given.
176.sp
177.LP
178One of the following messages will appear:
179.br
180.B "MAGIC NUMBER WRONG"
181.br
182.B "NCG OUT OF RANGE"
183.br
184.B "CPG OUT OF RANGE"
185.br
186.B "NCYL DOES NOT JIVE WITH NCG*CPG"
187.br
188.B "SIZE PREPOSTEROUSLY LARGE"
189.br
190.B "TRASHED VALUES IN SUPER BLOCK"
191.sp
192and will be followed by the message:
193.br
194.B "\fIF\fP: BAD SUPER BLOCK: \fIB\fP"
195.br
196.B "USE -b OPTION TO FSCK TO SPECIFY LOCATION OF AN ALTERNATE"
197.br
198.B "SUPER-BLOCK TO SUPPLY NEEDED INFORMATION; SEE fsck(8)."
199.br
200The super block has been corrupted.
201An alternative super block must be selected from among those
202listed by
203.I newfs
204(8) when the file system was created.
205For file systems with a blocksize less than 32K,
206specifying \-b 32 is a good first choice.
207.sp
208.LP
209.B "INTERNAL INCONSISTENCY: \fIM\fP"
210.br
211.I Fsck 's
212has had an internal panic, whose message is specified as \fIM\fP.
213This should never happen.
214See a guru.
215.sp
216.LP
217.B "CAN NOT SEEK: BLK \fIB\fP (CONTINUE)"
218.br
219.I Fsck 's
220request for moving to a specified block number \fIB\fP in
221the file system failed.
222This should never happen.
223See a guru.
224.LP
225Possible responses to the CONTINUE prompt are:
226.IP YES
227attempt to continue to run the file system check.
228Often,
229however the problem will persist.
230This error condition will not allow a complete check of the file system.
231A second run of
232.I fsck
233should be made to re-check this file system.
234If the block was part of the virtual memory buffer
235cache,
236.I fsck
237will terminate with the message ``Fatal I/O error''.
238.IP NO
239terminate the program.
240.sp
241.LP
242.B "CAN NOT READ: BLK \fIB\fP (CONTINUE)"
243.br
244.I Fsck 's
245request for reading a specified block number \fIB\fP in
246the file system failed.
247This should never happen.
248See a guru.
249.LP
250Possible responses to the CONTINUE prompt are:
251.IP YES
252attempt to continue to run the file system check.
253Often,
254however,
255the problem will persist.
256This error condition will not allow a complete check of the file system.
257A second run of
258.I fsck
259should be made to re-check this file system.
260If the block was part of the virtual memory buffer
261cache,
262.I fsck
263will terminate with the message ``Fatal I/O error''.
264.IP NO
265terminate the program.
266.sp
267.LP
268.B "CAN NOT WRITE: BLK \fIB\fP (CONTINUE)"
269.br
270.I Fsck 's
271request for writing a specified block number \fIB\fP
272in the file system failed.
273The disk is write-protected.
274See a guru.
275.LP
276Possible responses to the CONTINUE prompt are:
277.IP YES
278attempt to continue to run the file system check.
279Often,
280however,
281the problem will persist.
282This error condition will not allow a complete check of the file system.
283A second run of
284.I fsck
285should be made to re-check this file system.
286If the block was part of the virtual memory buffer
287cache,
288.I fsck
289will terminate with the message ``Fatal I/O error''.
290.IP NO
291terminate the program.
292.NH 2
293Phase 1 \- Check Blocks and Sizes
294.PP
295This phase concerns itself with
296the inode list.
297This section lists error conditions resulting from
298checking inode types,
299setting up the zero-link-count table,
300examining inode block numbers for bad or duplicate blocks,
301checking inode size,
302and checking inode format.
303All errors in this phase except
304.B "INCORRECT BLOCK COUNT"
305are fatal if the file system is being preen'ed,
306.sp
307.LP
308.B "CG \fIC\fP: BAD MAGIC NUMBER"
309The magic number of cylinder group \fIC\fP is wrong.
310This usually indicates that the cylinder group maps have been destroyed.
311When running manually the cylinder group is marked as needing
312to be reconstructed.
313.sp
314.LP
315.B "UNKNOWN FILE TYPE I=\fII\fP (CLEAR)"
316The mode word of the inode \fII\fP indicates that the inode is not a
317special block inode, special character inode, socket inode, regular inode,
318symbolic link, or directory inode.
319.LP
320Possible responses to the CLEAR prompt are:
321.IP YES
322de-allocate inode \fII\fP by zeroing its contents.
323This will always invoke the UNALLOCATED error condition in Phase 2
324for each directory entry pointing to this inode.
325.IP NO
326ignore this error condition.
327.sp
328.LP
329.B "LINK COUNT TABLE OVERFLOW (CONTINUE)"
330.br
331An internal table for
332.I fsck
333containing allocated inodes with a link count of
334zero has no more room.
335Recompile
336.I fsck
337with a larger value of MAXLNCNT.
338.LP
339Possible responses
340to the CONTINUE prompt are:
341.IP YES
342continue with the program.
343This error condition will not allow a complete check of the file system.
344A second run of
345.I fsck
346should be made to re-check this file system.
347If another allocated inode with a zero link count is found,
348this error condition is repeated.
349.IP NO
350terminate the program.
351.sp
352.LP
353.B "\fIB\fP BAD I=\fII\fP"
354.br
355Inode \fII\fP contains block number \fIB\fP with a number
356lower than the number of the first data block in the file system or
357greater than the number of the last block
358in the file system.
359This error condition may invoke the
360.B "EXCESSIVE BAD BLKS"
361error condition in Phase 1 if
362inode \fII\fP has too many block numbers outside the file system range.
363This error condition will always invoke the
364.B "BAD/DUP"
365error condition in Phase 2 and Phase 4.
366.sp
367.LP
368.B "EXCESSIVE BAD BLKS I=\fII\fP (CONTINUE)"
369.br
370There is more than a tolerable number (usually 10) of blocks with a number
371lower than the number of the first data block in the file system or greater than
372the number of last block in the file system associated with inode \fII\fP.
373.LP
374Possible responses to the CONTINUE prompt are:
375.IP YES
376ignore the rest of the blocks in this inode
377and continue checking with the next inode in the file system.
378This error condition will not allow a complete check of the file system.
379A second run of
380.I fsck
381should be made to re-check this file system.
382.IP NO
383terminate the program.
384.sp
385.LP
386.B "\fIB\fP DUP I=\fII\fP"
387.br
388Inode \fII\fP contains block number \fIB\fP which is already claimed by
389another inode.
390This error condition may invoke the
391.B "EXCESSIVE DUP BLKS"
392error condition in Phase 1 if
393inode \fII\fP has too many block numbers claimed by other inodes.
394This error condition will always invoke Phase 1b and the
395.B "BAD/DUP"
396error condition in Phase 2 and Phase 4.
397.sp
398.LP
399.B "EXCESSIVE DUP BLKS I=\fII\fP (CONTINUE)"
400.br
401There is more than a tolerable number (usually 10) of blocks claimed by other
402inodes.
403.LP
404Possible responses to the CONTINUE prompt are:
405.IP YES
406ignore the rest of the blocks in this inode
407and continue checking with the next inode in the file system.
408This error condition will not allow a complete check of the file system.
409A second run of
410.I fsck
411should be made to re-check this file system.
412.IP NO
413terminate the program.
414.sp
415.LP
416.B "DUP TABLE OVERFLOW (CONTINUE)"
417.br
418An internal table in
419.I fsck
420containing duplicate block numbers has no more room.
421Recompile
422.I fsck
423with a larger value of DUPTBLSIZE.
424.LP
425Possible responses to the CONTINUE prompt are:
426.IP YES
427continue with the program.
428This error condition will not allow a complete check of the file system.
429A second run of
430.I fsck
431should be made to re-check this file system.
432If another duplicate block is found, this error condition will repeat.
433.IP NO
434terminate the program.
435.sp
436.LP
437.B "PARTIALLY ALLOCATED INODE I=\fII\fP (CLEAR)"
438.br
439Inode \fII\fP is neither allocated nor unallocated.
440.LP
441Possible responses to the CLEAR prompt are:
442.IP YES
443de-allocate inode \fII\fP by zeroing its contents.
444.IP NO
445ignore this error condition.
446.sp
447.LP
448.B "INCORRECT BLOCK COUNT I=\fII\fP (\fIX\fP should be \fIY\fP) (CORRECT)"
449.br
450The block count for inode \fII\fP is \fIX\fP blocks,
451but should be \fIY\fP blocks.
452When preen'ing the count is corrected.
453.LP
454Possible responses to the CORRECT prompt are:
455.IP YES
456replace the block count of inode \fII\fP with \fIY\fP.
457.IP NO
458ignore this error condition.
459.NH 2
460Phase 1B: Rescan for More Dups
461.PP
462When a duplicate block is found in the file system, the file system is
463rescanned to find the inode which previously claimed that block.
464This section lists the error condition when the duplicate block is found.
465.sp
466.LP
467.B "\fIB\fP DUP I=\fII\fP"
468.br
469Inode \fII\fP contains block number \fIB\fP that
470is already claimed by another inode.
471This error condition will always invoke the
472.B "BAD/DUP"
473error condition in Phase 2.
474You can determine which inodes have overlapping blocks by examining
475this error condition and the DUP error condition in Phase 1.
476.NH 2
477Phase 2 \- Check Pathnames
478.PP
479This phase concerns itself with removing directory entries
480pointing to
481error conditioned inodes
482from Phase 1 and Phase 1b.
483This section lists error conditions resulting from
484root inode mode and status,
485directory inode pointers in range,
486and directory entries pointing to bad inodes.
487All errors in this phase are fatal if the file system is being preen'ed.
488.sp
489.LP
490.B "ROOT INODE UNALLOCATED. TERMINATING."
491.br
492The root inode (usually inode number 2) has no allocate mode bits.
493This should never happen.
494The program will terminate.
495.sp
496.LP
497.B "NAME TOO LONG \fIF\fP"
498.br
499An excessively long path name has been found.
500This is usually indicative of loops in the file system name space.
501This can occur if the super user has made circular links to directories.
502The offending links must be removed (by a guru).
503.sp
504.LP
505.B "ROOT INODE NOT DIRECTORY (FIX)"
506.br
507The root inode (usually inode number 2)
508is not directory inode type.
509.LP
510Possible responses to the FIX prompt are:
511.IP YES
512replace the root inode's type to be a directory.
513If the root inode's data blocks are not directory blocks,
514a VERY large number of error conditions will be produced.
515.IP NO
516terminate the program.
517.sp
518.LP
519.B "DUPS/BAD IN ROOT INODE (CONTINUE)"
520.br
521Phase 1 or Phase 1b have found duplicate blocks
522or bad blocks in the root inode (usually inode number 2) for the file system.
523.LP
524Possible responses to the CONTINUE prompt are:
525.IP YES
526ignore the
527.B "DUPS/BAD"
528error condition in the root inode and
529attempt to continue to run the file system check.
530If the root inode is not correct,
531then this may result in a large number of other error conditions.
532.IP NO
533terminate the program.
534.sp
535.LP
536.B "I OUT OF RANGE I=\fII\fP NAME=\fIF\fP (REMOVE)"
537.br
538A directory entry \fIF\fP has an inode number \fII\fP which is greater than
539the end of the inode list.
540.LP
541Possible responses to the REMOVE prompt are:
542.IP YES
543the directory entry \fIF\fP is removed.
544.IP NO
545ignore this error condition.
546.sp
547.LP
548.B "UNALLOCATED I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (REMOVE)"
549.br
550A directory entry \fIF\fP has a directory inode \fII\fP
551without allocate mode bits.
552The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, modify time \fIT\fP,
553and directory name \fIF\fP are printed.
554.LP
555Possible responses to the REMOVE prompt are:
556.IP YES
557the directory entry \fIF\fP is removed.
558.IP NO
559ignore this error condition.
560.sp
561.LP
562.B "UNALLOCATED I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP FILE=\fIF\fP (REMOVE)"
563.br
564A directory entry \fIF\fP has an inode \fII\fP
565without allocate mode bits.
566The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, modify time \fIT\fP, and file name \fIF\fP are printed.
567.LP
568Possible responses to the REMOVE prompt are:
569.IP YES
570the directory entry \fIF\fP is removed.
571.IP NO
572ignore this error condition.
573.sp
574.LP
575.B "DUP/BAD I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (REMOVE)"
576.br
577Phase 1 or Phase 1b have found duplicate blocks or bad blocks
578associated with directory entry \fIF\fP, directory inode \fII\fP.
579The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, modify time \fIT\fP, and directory name \fIF\fP are printed.
580.LP
581Possible responses to the REMOVE prompt are:
582.IP YES
583the directory entry \fIF\fP is removed.
584.IP NO
585ignore this error condition.
586.sp
587.LP
588.B "DUP/BAD I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP FILE=\fIF\fP (REMOVE)"
589.br
590Phase 1 or Phase 1b have found duplicate blocks or bad blocks
591associated with directory entry \fIF\fP, inode \fII\fP.
592The owner \fIO\fP, mode \fIM\fP, size \fIS\fP,
593modify time \fIT\fP, and file name \fIF\fP are printed.
594.LP
595Possible responses to the REMOVE prompt are:
596.IP YES
597the directory entry \fIF\fP is removed.
598.IP NO
599ignore this error condition.
600.sp
601.LP
602.B "ZERO LENGTH DIRECTORY I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (REMOVE)"
603.br
604A directory entry \fIF\fP has a size \fIS\fP that is zero.
605The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, modify time \fIT\fP,
606and directory name \fIF\fP are printed.
607.LP
608Possible responses to the REMOVE prompt are:
609.IP YES
610the directory entry \fIF\fP is removed;
611this will always invoke the BAD/DUP error condition in Phase 4.
612.IP NO
613ignore this error condition.
614.sp
615.LP
616.B "DIRECTORY TOO SHORT I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (FIX)"
617.br
618A directory \fIF\fP has been found whose size \fIS\fP
619is less than the minimum size directory.
620The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, modify time \fIT\fP,
621and directory name \fIF\fP are printed.
622.LP
623Possible responses to the FIX prompt are:
624.IP YES
625increase the size of the directory to the minimum directory size.
626.IP NO
627ignore this directory.
628.sp
629.LP
630.B "DIRECTORY CORRUPTED I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (SALVAGE)"
631.br
632A directory with an inconsistent internal state has been found.
633.LP
634Possible responses to the FIX prompt are:
635.IP YES
636throw away all entries up to the next 512-byte boundary.
637This rather drastic action can throw away up to 42 entries,
638and should be taken only after other recovery efforts have failed.
639.IP NO
640Skip up to the next 512-byte boundary and resume reading,
641but do not modify the directory.
642.sp
643.LP
644.B "BAD INODE NUMBER FOR `.' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (FIX)"
645.br
646A directory \fII\fP has been found whose inode number for `.' does
647does not equal \fII\fP.
648.LP
649Possible responses to the FIX prompt are:
650.IP YES
651change the inode number for `.' to be equal to \fII\fP.
652.IP NO
653leave the inode number for `.' unchanged.
654.sp
655.LP
656.B "MISSING `.' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (FIX)"
657.br
658A directory \fII\fP has been found whose first entry is unallocated.
659.LP
660Possible responses to the FIX prompt are:
661.IP YES
662make an entry for `.' with inode number equal to \fII\fP.
663.IP NO
664leave the directory unchanged.
665.sp
666.LP
667.B "MISSING `.' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP"
668.br
669.B "CANNOT FIX, FIRST ENTRY IN DIRECTORY CONTAINS \fIF\fP"
670.br
671A directory \fII\fP has been found whose first entry is \fIF\fP.
672.I Fsck
673cannot resolve this problem.
674The file system should be mounted and the offending entry \fIF\fP
675moved elsewhere.
676The file system should then be unmounted and
677.I fsck
678should be run again.
679.sp
680.LP
681.B "MISSING `.' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP"
682.br
683.B "CANNOT FIX, INSUFFICIENT SPACE TO ADD `.'"
684.br
685A directory \fII\fP has been found whose first entry is not `.'.
686.I Fsck
687cannot resolve this problem as it should never happen.
688See a guru.
689.sp
690.LP
691.B "EXTRA `.' ENTRY I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (FIX)"
692.br
693A directory \fII\fP has been found that has more than one entry for `.'.
694.LP
695Possible responses to the FIX prompt are:
696.IP YES
697remove the extra entry for `.'.
698.IP NO
699leave the directory unchanged.
700.sp
701.LP
702.B "BAD INODE NUMBER FOR `..' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (FIX)"
703.br
704A directory \fII\fP has been found whose inode number for `..' does
705does not equal the parent of \fII\fP.
706.LP
707Possible responses to the FIX prompt are:
708.IP YES
709change the inode number for `..' to be equal to the parent of \fII\fP.
710.IP NO
711leave the inode number for `..' unchanged.
712.sp
713.LP
714.B "MISSING `..' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (FIX)"
715.br
716A directory \fII\fP has been found whose second entry is unallocated.
717.LP
718Possible responses to the FIX prompt are:
719.IP YES
720make an entry for `..' with inode number equal to the parent of \fII\fP.
721.IP NO
722leave the directory unchanged.
723.sp
724.LP
725.B "MISSING `..' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP"
726.br
727.B "CANNOT FIX, SECOND ENTRY IN DIRECTORY CONTAINS \fIF\fP"
728.br
729A directory \fII\fP has been found whose second entry is \fIF\fP.
730.I Fsck
731cannot resolve this problem.
732The file system should be mounted and the offending entry \fIF\fP
733moved elsewhere.
734The file system should then be unmounted and
735.I fsck
736should be run again.
737.sp
738.LP
739.B "MISSING `..' I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP"
740.br
741.B "CANNOT FIX, INSUFFICIENT SPACE TO ADD `..'"
742.br
743A directory \fII\fP has been found whose second entry is not `..'.
744.I Fsck
745cannot resolve this problem as it should never happen.
746See a guru.
747.sp
748.LP
749.B "EXTRA `..' ENTRY I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP DIR=\fIF\fP (FIX)"
750.br
751A directory \fII\fP has been found that has more than one entry for `..'.
752.LP
753Possible responses to the FIX prompt are:
754.IP YES
755remove the extra entry for `..'.
756.IP NO
757leave the directory unchanged.
758.NH 2
759Phase 3 \- Check Connectivity
760.PP
761This phase concerns itself with the directory connectivity seen in
762Phase 2.
763This section lists error conditions resulting from
764unreferenced directories,
765and missing or full
766.I lost+found
767directories.
768.sp
769.LP
770.B "UNREF DIR I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP (RECONNECT)"
771.br
772The directory inode \fII\fP was not connected to a directory entry
773when the file system was traversed.
774The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, and modify time \fIT\fP of directory
775inode \fII\fP are printed.
776When preen'ing, the directory is reconnected if its size is non-zero,
777otherwise it is cleared.
778.LP
779Possible responses to the RECONNECT prompt are:
780.IP YES
781reconnect directory inode \fII\fP to the file system in the
782directory for lost files (usually \fIlost+found\fP).
783This may invoke the
784.I lost+found
785error condition in Phase 3
786if there are problems connecting directory inode \fII\fP to \fIlost+found\fP.
787This may also invoke the CONNECTED error condition in Phase 3 if the link
788was successful.
789.IP NO
790ignore this error condition.
791This will always invoke the UNREF error condition in Phase 4.
792.sp
793.LP
794.B "SORRY. NO lost+found DIRECTORY"
795.br
796There is no
797.I lost+found
798directory in the root directory of the file system;
799.I fsck
800ignores the request to link a directory in
801.I lost+found .
802This will always invoke the UNREF error condition in Phase 4.
803Check access modes of
804.I lost+found .
805See
806.I fsck (8)
807manual entry
808for further detail.
809This error is fatal if the file system is being preen'ed.
810.sp
811.LP
812.B "SORRY. NO SPACE IN lost+found DIRECTORY"
813.br
814There is no space to add another entry to the
815.I lost+found
816directory in the root directory
817of the file system;
818.I fsck
819ignores the request to link a directory in \fIlost+found\fP.
820This will always invoke the UNREF error condition in Phase 4.
821Clean out unnecessary entries in
822.I lost+found
823or make
824.I lost+found
825larger.
826See
827.I fsck (8)
828manual entry for further detail.
829This error is fatal if the file system is being preen'ed.
830.sp
831.LP
832.B "DIR I=\fII1\fP CONNECTED. PARENT WAS I=\fII2\fP"
833.br
834This is an advisory message indicating a directory inode \fII1\fP was
835successfully connected to the
836.I lost+found
837directory.
838The parent inode \fII2\fP of the directory inode \fII1\fP is
839replaced by the inode number of the
840.I lost+found
841directory.
842.NH 2
843Phase 4 \- Check Reference Counts
844.PP
845This phase concerns itself with the link count information
846seen in Phase 2 and Phase 3.
847This section lists error conditions resulting from
848unreferenced files,
849missing or full
850.I lost+found
851directory,
852incorrect link counts for files, directories, symbolic links, or special files,
853unreferenced files, symbolic links, and directories,
854bad and duplicate blocks in files, symbolic links, and directories,
855and incorrect total free-inode counts.
856All errors in this phase are correctable if the file system is being preen'ed
857except running out of space in the lost+found directory.
858.sp
859.LP
860.B "UNREF FILE I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP (RECONNECT)"
861.br
862Inode \fII\fP was not connected to a directory entry
863when the file system was traversed.
864The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, and
865modify time \fIT\fP of inode \fII\fP are printed.
866When preen'ing the file is cleared if either its size or its
867link count is zero,
868otherwise it is reconnected.
869.LP
870Possible responses to the RECONNECT prompt are:
871.IP YES
872reconnect inode \fII\fP to the file system in the directory for
873lost files (usually \fIlost+found\fP).
874This may invoke the
875.I lost+found
876error condition in Phase 4
877if there are problems connecting inode \fII\fP to
878.I lost+found.
879.IP NO
880ignore this error condition.
881This will always invoke the CLEAR error condition in Phase 4.
882.sp
883.LP
884.B "(CLEAR)"
885.br
886The inode mentioned in the immediately previous error condition can not be
887reconnected.
888This cannot occur if the file system is being preen'ed,
889since lack of space to reconnect files is a fatal error.
890.LP
891Possible responses to the CLEAR prompt are:
892.IP YES
893de-allocate the inode mentioned in the immediately previous error condition by zeroing its contents.
894.IP NO
895ignore this error condition.
896.sp
897.LP
898.B "SORRY. NO lost+found DIRECTORY"
899.br
900There is no
901.I lost+found
902directory in the root directory of the file system;
903.I fsck
904ignores the request to link a file in
905.I lost+found.
906This will always invoke the CLEAR error condition in Phase 4.
907Check access modes of
908.I lost+found .
909This error is fatal if the file system is being preen'ed.
910.sp
911.LP
912.B "SORRY. NO SPACE IN lost+found DIRECTORY"
913.br
914There is no space to add another entry to the
915.I lost+found
916directory in the root directory of the
917file system;
918.I fsck
919ignores the request to link a file in
920.I lost+found.
921This will always invoke the CLEAR error condition in Phase 4.
922Check size and contents of
923.I lost+found.
924This error is fatal if the file system is being preen'ed.
925.sp
926.LP
927.B "LINK COUNT FILE I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP COUNT=\fIX\fP SHOULD BE \fIY\fP (ADJUST)"
928.br
929The link count for inode \fII\fP which is a file,
930is \fIX\fP but should be \fIY\fP.
931The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, and modify time \fIT\fP
932are printed.
933When preen'ing the link count is adjusted.
934.LP
935Possible responses to the ADJUST prompt are:
936.IP YES
937replace the link count of file inode \fII\fP with \fIY\fP.
938.IP NO
939ignore this error condition.
940.sp
941.LP
942.B "LINK COUNT DIR I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP COUNT=\fIX\fP SHOULD BE \fIY\fP (ADJUST)"
943.br
944The link count for inode \fII\fP which is a directory,
945is \fIX\fP but should be \fIY\fP.
946The owner \fIO\fP, mode \fIM\fP, size \fIS\fP, and modify time \fIT\fP
947of directory inode \fII\fP are printed.
948When preen'ing the link count is adjusted.
949.LP
950Possible responses to the ADJUST prompt are:
951.IP YES
952replace the link count of directory inode \fII\fP with \fIY\fP.
953.IP NO
954ignore this error condition.
955.sp
956.LP
957.B "LINK COUNT \fIF\fP I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP COUNT=\fIX\fP SHOULD BE \fIY\fP (ADJUST)"
958.br
959The link count for \fIF\fP inode \fII\fP is \fIX\fP but should be \fIY\fP.
960The name \fIF\fP,
961owner \fIO\fP, mode \fIM\fP, size \fIS\fP, and modify time
962\fIT\fP
963are printed.
964When preen'ing the link count is adjusted.
965.LP
966Possible responses to the ADJUST prompt are:
967.IP YES
968replace the link count of inode \fII\fP with \fIY\fP.
969.IP NO
970ignore this error condition.
971.sp
972.LP
973.B "UNREF FILE I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP (CLEAR)"
974.br
975Inode \fII\fP which is a file, was not connected to a directory entry when the
976file system was traversed.
977The owner \fIO\fP, mode \fIM\fP, size \fIS\fP,
978and modify time \fIT\fP of inode \fII\fP
979are printed.
980When preen'ing,
981this is a file that was not connected because its size or link count was zero,
982hence it is cleared.
983.LP
984Possible responses to the CLEAR prompt are:
985.IP YES
986de-allocate inode \fII\fP by zeroing its contents.
987.IP NO
988ignore this error condition.
989.sp
990.LP
991.B "UNREF DIR I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP (CLEAR)"
992.br
993Inode \fII\fP which is a directory,
994was not connected to a directory entry when the
995file system was traversed.
996The owner \fIO\fP, mode \fIM\fP, size \fIS\fP,
997and modify time \fIT\fP of inode \fII\fP
998are printed.
999When preen'ing,
1000this is a directory that was not connected
1001because its size or link count was zero,
1002hence it is cleared.
1003.LP
1004Possible responses to the CLEAR prompt are:
1005.IP YES
1006de-allocate inode \fII\fP by zeroing its contents.
1007.IP NO
1008ignore this error condition.
1009.sp
1010.LP
1011.B "BAD/DUP FILE I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP (CLEAR)"
1012.br
1013Phase 1 or Phase 1b have found duplicate blocks
1014or bad blocks associated with
1015file inode \fII\fP.
1016The owner \fIO\fP, mode \fIM\fP, size \fIS\fP,
1017and modify time \fIT\fP of inode \fII\fP
1018are printed.
1019This error cannot arise when the file system is being preen'ed,
1020as it would have caused a fatal error earlier.
1021.LP
1022Possible responses to the CLEAR prompt are:
1023.IP YES
1024de-allocate inode \fII\fP by zeroing its contents.
1025.IP NO
1026ignore this error condition.
1027.sp
1028.LP
1029.B "BAD/DUP DIR I=\fII\fP OWNER=\fIO\fP MODE=\fIM\fP SIZE=\fIS\fP MTIME=\fIT\fP (CLEAR)"
1030.br
1031Phase 1 or Phase 1b have found duplicate blocks or
1032bad blocks associated with directory inode \fII\fP.
1033The owner \fIO\fP, mode \fIM\fP, size \fIS\fP,
1034and modify time \fIT\fP of inode \fII\fP
1035are printed.
1036This error cannot arise when the file system is being preen'ed,
1037as it would have caused a fatal error earlier.
1038.LP
1039Possible responses to the CLEAR prompt are:
1040.IP YES
1041de-allocate inode \fII\fP by zeroing its contents.
1042.IP NO
1043ignore this error condition.
1044.sp
1045.LP
1046.B "FREE INODE COUNT WRONG IN SUPERBLK (FIX)"
1047.br
1048The actual count of the free inodes does not
1049match the count in the super-block
1050of the file system.
1051When preen'ing,
1052the count is fixed.
1053.LP
1054Possible responses to the FIX prompt are:
1055.IP YES
1056replace the count in the super-block by the actual count.
1057.IP NO
1058ignore this error condition.
1059.NH 2
1060Phase 5 - Check Cyl groups
1061.PP
1062This phase concerns itself with the free-block maps.
1063This section lists error conditions resulting from
1064allocated blocks in the free-block maps,
1065free blocks missing from free-block maps,
1066and the total free-block count incorrect.
1067.sp
1068.LP
1069.B "CG \fIC\fP: BAD MAGIC NUMBER"
1070.br
1071The magic number of cylinder group \fIC\fP is wrong.
1072This usually indicates that the cylinder group maps have been destroyed.
1073When running manually the cylinder group is marked as needing
1074to be reconstructed.
1075This error is fatal if the file system is being preen'ed.
1076.sp
1077.LP
1078.B "EXCESSIVE BAD BLKS IN BIT MAPS (CONTINUE)"
1079.br
1080An inode contains
1081more than a tolerable number (usually 10) of blocks
1082claimed by other inodes or that are out of the legal range
1083for the file system.
1084This error is fatal if the file system is being preen'ed.
1085.LP
1086Possible responses to the CONTINUE prompt are:
1087.IP YES
1088ignore the rest of the free-block maps and continue the execution of
1089.I fsck.
1090.IP NO
1091terminate the program.
1092.sp
1093.LP
1094.B "SUMMARY INFORMATION \fIT\fP BAD"
1095.br
1096where \fIT\fP is one or more of:
1097.br
1098.B "(INODE FREE)"
1099.br
1100.B "(BLOCK OFFSETS)"
1101.br
1102.B "(FRAG SUMMARIES)"
1103.br
1104.B "(SUPER BLOCK SUMMARIES)"
1105.br
1106The indicated summary information was found to be incorrect.
1107This error condition will always invoke the
1108.B "BAD CYLINDER GROUPS"
1109condition in Phase 6.
1110When preen'ing,
1111the summary information is recomputed.
1112.sp
1113.LP
1114.B "\fIX\fP BLK(S) MISSING"
1115.br
1116\fIX\fP blocks
1117unused by the file system were not found in the free-block maps.
1118This error condition will always invoke the
1119.B "BAD CYLINDER GROUPS"
1120condition in Phase 6.
1121When preen'ing,
1122the block maps are rebuilt.
1123.sp
1124.LP
1125.B "BAD CYLINDER GROUPS (SALVAGE)"
1126.br
1127Phase 5 has found
1128bad blocks in the free-block maps,
1129duplicate blocks in the free-block maps,
1130or blocks missing from the file system.
1131When preen'ing,
1132the cylinder groups are reconstructed.
1133.LP
1134Possible responses to the SALVAGE prompt are:
1135.IP YES
1136replace the actual free-block maps with a new free-block maps.
1137.IP NO
1138ignore this error condition.
1139.sp
1140.LP
1141.B "FREE BLK COUNT WRONG IN SUPERBLOCK (FIX)"
1142.br
1143The actual count of free blocks does not match the count in the
1144super-block of the file system.
1145When preen'ing,
1146the counts are fixed.
1147.LP
1148Possible responses to the FIX prompt are:
1149.IP YES
1150replace the count in the super-block by the actual count.
1151.IP NO
1152ignore this error condition.
1153.NH 2
1154Phase 6 - Salvage Cylinder Groups
1155.PP
1156This phase concerns itself with the free-block maps reconstruction.
1157No error messages are produced.
1158.NH 2
1159Cleanup
1160.PP
1161Once a file system has been checked, a few cleanup functions are performed.
1162This section lists advisory messages about
1163the file system
1164and modify status of the file system.
1165.sp
1166.LP
1167.B "\fIV\fP files, \fIW\fP used, \fIX\fP free (\fIY\fP frags, \fIZ\fP blocks)"
1168.br
1169This is an advisory message indicating that
1170the file system checked contained
1171\fIV\fP files using
1172\fIW\fP fragment sized blocks leaving
1173\fIX\fP fragment sized blocks free in the file system.
1174The numbers in parenthesis breaks the free count down into
1175\fIY\fP free fragments and
1176\fIZ\fP free full sized blocks.
1177.sp
1178.LP
1179.B "***** REBOOT UNIX *****"
1180.br
1181This is an advisory message indicating that
1182the root file system has been modified by
1183.I fsck.
1184If UNIX is not rebooted immediately,
1185the work done by
1186.I fsck
1187may be undone by the in-core copies of tables
1188UNIX keeps.
1189When preen'ing,
1190.I fsck
1191will exit with a code of 4.
1192The auto-reboot script interprets an exit code of 4
1193by issuing a reboot system call.
1194.sp
1195.LP
1196.B "***** FILE SYSTEM WAS MODIFIED *****"
1197.br
1198This is an advisory message indicating that
1199the current file system was modified by
1200.I fsck.
1201If this file system is mounted or is the current root file system,
1202.I fsck
1203should be halted and UNIX rebooted.
1204If UNIX is not rebooted immediately,
1205the work done by
1206.I fsck
1207may be undone by the in-core copies of tables
1208UNIX keeps.